zebra/zebra-rpc/Cargo.toml

96 lines
3.2 KiB
TOML
Raw Normal View History

[package]
name = "zebra-rpc"
2024-01-23 12:00:38 -08:00
version = "1.0.0-beta.34"
authors = ["Zcash Foundation <zebra@zfnd.org>"]
change(crates): Prepare for publishing crates to crates.io (#6908) * change(crates): Publish tower-batch-control * Cargo fields for zebra-test * Cargo fields for tower-fallback * Cargo fields for zebra-chain * Cargo fields for zebra-consensus * Cargo fields for zebra-network * Cargo fields for zebra-node-services * Cargo fields for zebra-rpc * Cargo fields for zebra-script * Cargo fields for zebra-state * Cargo fields for zebrad * Cargo fields for zebra-test * Include zebra-test version and path for zebra-chain * Include zebra-chain version and path for zebra-node-services * Include zebra-chain version and path for zebra-script * Include zebra-chain and zebra-test versions and paths for zebra-state * Include zebra-* versions and paths for zebra-consensus * Include zebra-* and tower-fallback versions and paths for tower-batch-control * Include tower-* versions and paths for zebra-consensus * Fixed tower-fallback license string * Remove versions for dev-dependencise * Update zebra-rpc/Cargo.toml Co-authored-by: teor <teor@riseup.net> * tower-batch-control license MUST remain MIT only * Align zebra-network with upstream tower's MIT license * Update zebra-test/Cargo.toml Co-authored-by: teor <teor@riseup.net> * Update zebra-utils/Cargo.toml Co-authored-by: teor <teor@riseup.net> * fix(legal): Use correct licenses for tower-batch-control and zebra-network (#6927) * Don't modify whitespace * Resolve rustdoc and cargo-release warnings * Add missing zebra internal dependency versions * Workaround missing zebra-utils test dependency in zebrad test-only feature * Fix missing zebra internal dependency versions * Add README, home page, and search terms to every crate * Fix README publish warnings * Change tower crates to beta versions * Add zebra-utils to the list of allowed unused dependencies * Update tower-batch-control/Cargo.toml * Update tower-fallback/Cargo.toml --------- Co-authored-by: teor <teor@riseup.net>
2023-06-13 01:46:01 -07:00
description = "A Zebra JSON Remote Procedure Call (JSON-RPC) interface"
license = "MIT OR Apache-2.0"
change(crates): Prepare for publishing crates to crates.io (#6908) * change(crates): Publish tower-batch-control * Cargo fields for zebra-test * Cargo fields for tower-fallback * Cargo fields for zebra-chain * Cargo fields for zebra-consensus * Cargo fields for zebra-network * Cargo fields for zebra-node-services * Cargo fields for zebra-rpc * Cargo fields for zebra-script * Cargo fields for zebra-state * Cargo fields for zebrad * Cargo fields for zebra-test * Include zebra-test version and path for zebra-chain * Include zebra-chain version and path for zebra-node-services * Include zebra-chain version and path for zebra-script * Include zebra-chain and zebra-test versions and paths for zebra-state * Include zebra-* versions and paths for zebra-consensus * Include zebra-* and tower-fallback versions and paths for tower-batch-control * Include tower-* versions and paths for zebra-consensus * Fixed tower-fallback license string * Remove versions for dev-dependencise * Update zebra-rpc/Cargo.toml Co-authored-by: teor <teor@riseup.net> * tower-batch-control license MUST remain MIT only * Align zebra-network with upstream tower's MIT license * Update zebra-test/Cargo.toml Co-authored-by: teor <teor@riseup.net> * Update zebra-utils/Cargo.toml Co-authored-by: teor <teor@riseup.net> * fix(legal): Use correct licenses for tower-batch-control and zebra-network (#6927) * Don't modify whitespace * Resolve rustdoc and cargo-release warnings * Add missing zebra internal dependency versions * Workaround missing zebra-utils test dependency in zebrad test-only feature * Fix missing zebra internal dependency versions * Add README, home page, and search terms to every crate * Fix README publish warnings * Change tower crates to beta versions * Add zebra-utils to the list of allowed unused dependencies * Update tower-batch-control/Cargo.toml * Update tower-fallback/Cargo.toml --------- Co-authored-by: teor <teor@riseup.net>
2023-06-13 01:46:01 -07:00
repository = "https://github.com/ZcashFoundation/zebra"
edition = "2021"
change(crates): Prepare for publishing crates to crates.io (#6908) * change(crates): Publish tower-batch-control * Cargo fields for zebra-test * Cargo fields for tower-fallback * Cargo fields for zebra-chain * Cargo fields for zebra-consensus * Cargo fields for zebra-network * Cargo fields for zebra-node-services * Cargo fields for zebra-rpc * Cargo fields for zebra-script * Cargo fields for zebra-state * Cargo fields for zebrad * Cargo fields for zebra-test * Include zebra-test version and path for zebra-chain * Include zebra-chain version and path for zebra-node-services * Include zebra-chain version and path for zebra-script * Include zebra-chain and zebra-test versions and paths for zebra-state * Include zebra-* versions and paths for zebra-consensus * Include zebra-* and tower-fallback versions and paths for tower-batch-control * Include tower-* versions and paths for zebra-consensus * Fixed tower-fallback license string * Remove versions for dev-dependencise * Update zebra-rpc/Cargo.toml Co-authored-by: teor <teor@riseup.net> * tower-batch-control license MUST remain MIT only * Align zebra-network with upstream tower's MIT license * Update zebra-test/Cargo.toml Co-authored-by: teor <teor@riseup.net> * Update zebra-utils/Cargo.toml Co-authored-by: teor <teor@riseup.net> * fix(legal): Use correct licenses for tower-batch-control and zebra-network (#6927) * Don't modify whitespace * Resolve rustdoc and cargo-release warnings * Add missing zebra internal dependency versions * Workaround missing zebra-utils test dependency in zebrad test-only feature * Fix missing zebra internal dependency versions * Add README, home page, and search terms to every crate * Fix README publish warnings * Change tower crates to beta versions * Add zebra-utils to the list of allowed unused dependencies * Update tower-batch-control/Cargo.toml * Update tower-fallback/Cargo.toml --------- Co-authored-by: teor <teor@riseup.net>
2023-06-13 01:46:01 -07:00
readme = "../README.md"
homepage = "https://zfnd.org/zebra/"
# crates.io is limited to 5 keywords and categories
keywords = ["zebra", "zcash"]
# Must be one of <https://crates.io/category_slugs>
categories = ["asynchronous", "cryptography::cryptocurrencies", "encoding", "network-programming"]
[features]
default = []
# Production features that activate extra dependencies, or extra features in dependencies
feat(mine): Add an internal Zcash miner to Zebra (#8136) * Patch equihash to use the solver branch * Add an internal-miner feature and set up its dependencies * Remove 'Experimental' from mining RPC docs * Fix a nightly clippy::question_mark lint * Move a byte array utility function to zebra-chain * fixup! Add an internal-miner feature and set up its dependencies * Add an equihash::Solution::solve() method with difficulty checks * Check solution is valid before returning it * Add a TODO to check for peers before mining * Move config validation into GetBlockTemplateRpcImpl::new() * fixup! fixup! Add an internal-miner feature and set up its dependencies * Use the same generic constraints for GetBlockTemplateRpcImpl struct and impls * Start adding an internal miner component * Add the miner task to the start command * Add basic miner code * Split out a method to mine one block * Spawn to a blocking thread * Wait until a valid template is available * Handle shutdown * Run mining on low priority threads * Ignore some invalid solutions * Use a difference nonce for each solver thread * Update TODOs * Change the patch into a renamed dependency to simplify crate releases * Clean up instrumentation and TODOs * Make RPC instances cloneable and clean up generics * Make LongPollId Copy so it's easier to use * Add API to restart mining if there's a new block template * Actually restart mining if there's a new block template * Tidy instrumentation * fixup! Move config validation into GetBlockTemplateRpcImpl::new() * fixup! Make RPC instances cloneable and clean up generics * Run the template generator and one miner concurrently * Reduce logging * Fix a bug in getblocktemplate RPC tip change detection * Work around some watch channel change bugs * Rate-limit template changes in the receiver * Run one mining solver per available core * Use updated C code with double-free protection * Update to the latest solver branch * Return and submit all valid solutions * Document what INPUT_LENGTH means * Fix watch channel change detection * Don't return early when a mining task fails * Spawn async miner tasks to avoid cooperative blocking, deadlocks, and improve shutdown responsiveness * Make existing parallelism docs and configs consistent * Add a mining parallelism config * Use the minimum of the configured or available threads for mining * Ignore optional feature fields in tests * Downgrade some frequent logs to debug * Document new zebrad features and tasks * Describe the internal-miner feature in the CHANGELOG * Update dependency to de-duplicate equihash solutions * Use futures::StreamExt instead of TryStreamExt * Fix a panic message typo
2024-01-11 06:41:01 -08:00
# Mining RPC support
getblocktemplate-rpcs = [
"rand",
"zcash_address",
"zebra-consensus/getblocktemplate-rpcs",
"zebra-state/getblocktemplate-rpcs",
"zebra-node-services/getblocktemplate-rpcs",
"zebra-chain/getblocktemplate-rpcs",
]
feat(mine): Add an internal Zcash miner to Zebra (#8136) * Patch equihash to use the solver branch * Add an internal-miner feature and set up its dependencies * Remove 'Experimental' from mining RPC docs * Fix a nightly clippy::question_mark lint * Move a byte array utility function to zebra-chain * fixup! Add an internal-miner feature and set up its dependencies * Add an equihash::Solution::solve() method with difficulty checks * Check solution is valid before returning it * Add a TODO to check for peers before mining * Move config validation into GetBlockTemplateRpcImpl::new() * fixup! fixup! Add an internal-miner feature and set up its dependencies * Use the same generic constraints for GetBlockTemplateRpcImpl struct and impls * Start adding an internal miner component * Add the miner task to the start command * Add basic miner code * Split out a method to mine one block * Spawn to a blocking thread * Wait until a valid template is available * Handle shutdown * Run mining on low priority threads * Ignore some invalid solutions * Use a difference nonce for each solver thread * Update TODOs * Change the patch into a renamed dependency to simplify crate releases * Clean up instrumentation and TODOs * Make RPC instances cloneable and clean up generics * Make LongPollId Copy so it's easier to use * Add API to restart mining if there's a new block template * Actually restart mining if there's a new block template * Tidy instrumentation * fixup! Move config validation into GetBlockTemplateRpcImpl::new() * fixup! Make RPC instances cloneable and clean up generics * Run the template generator and one miner concurrently * Reduce logging * Fix a bug in getblocktemplate RPC tip change detection * Work around some watch channel change bugs * Rate-limit template changes in the receiver * Run one mining solver per available core * Use updated C code with double-free protection * Update to the latest solver branch * Return and submit all valid solutions * Document what INPUT_LENGTH means * Fix watch channel change detection * Don't return early when a mining task fails * Spawn async miner tasks to avoid cooperative blocking, deadlocks, and improve shutdown responsiveness * Make existing parallelism docs and configs consistent * Add a mining parallelism config * Use the minimum of the configured or available threads for mining * Ignore optional feature fields in tests * Downgrade some frequent logs to debug * Document new zebrad features and tasks * Describe the internal-miner feature in the CHANGELOG * Update dependency to de-duplicate equihash solutions * Use futures::StreamExt instead of TryStreamExt * Fix a panic message typo
2024-01-11 06:41:01 -08:00
# Experimental internal miner support
internal-miner = []
# Test-only features
proptest-impl = [
"proptest",
"zebra-consensus/proptest-impl",
"zebra-state/proptest-impl",
"zebra-network/proptest-impl",
"zebra-chain/proptest-impl",
]
[dependencies]
build(deps): bump the prod group with 14 updates (#8264) * build(deps): bump the prod group with 14 updates Bumps the prod group with 14 updates: | Package | From | To | | --- | --- | --- | | [clap](https://github.com/clap-rs/clap) | `4.4.18` | `4.5.0` | | [chrono](https://github.com/chronotope/chrono) | `0.4.33` | `0.4.34` | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.2.2` | `2.2.3` | | [toml](https://github.com/toml-rs/toml) | `0.8.9` | `0.8.10` | | [thiserror](https://github.com/dtolnay/thiserror) | `1.0.56` | `1.0.57` | | [metrics](https://github.com/metrics-rs/metrics) | `0.22.0` | `0.22.1` | | [num-integer](https://github.com/rust-num/num-integer) | `0.1.45` | `0.1.46` | | [metrics-exporter-prometheus](https://github.com/metrics-rs/metrics) | `0.13.0` | `0.13.1` | | [indicatif](https://github.com/console-rs/indicatif) | `0.17.7` | `0.17.8` | | [tempfile](https://github.com/Stebalien/tempfile) | `3.9.0` | `3.10.0` | | [tonic](https://github.com/hyperium/tonic) | `0.10.2` | `0.11.0` | | [tonic-build](https://github.com/hyperium/tonic) | `0.10.2` | `0.11.0` | | [x25519-dalek](https://github.com/dalek-cryptography/curve25519-dalek) | `2.0.0` | `2.0.1` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.6.0` | `3.6.1` | Updates `clap` from 4.4.18 to 4.5.0 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.4.18...clap_complete-v4.5.0) Updates `chrono` from 0.4.33 to 0.4.34 - [Release notes](https://github.com/chronotope/chrono/releases) - [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md) - [Commits](https://github.com/chronotope/chrono/compare/v0.4.33...v0.4.34) Updates `indexmap` from 2.2.2 to 2.2.3 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.2...2.2.3) Updates `toml` from 0.8.9 to 0.8.10 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.9...toml-v0.8.10) Updates `thiserror` from 1.0.56 to 1.0.57 - [Release notes](https://github.com/dtolnay/thiserror/releases) - [Commits](https://github.com/dtolnay/thiserror/compare/1.0.56...1.0.57) Updates `metrics` from 0.22.0 to 0.22.1 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-v0.22.0...metrics-v0.22.1) Updates `num-integer` from 0.1.45 to 0.1.46 - [Changelog](https://github.com/rust-num/num-integer/blob/master/RELEASES.md) - [Commits](https://github.com/rust-num/num-integer/compare/num-integer-0.1.45...num-integer-0.1.46) Updates `metrics-exporter-prometheus` from 0.13.0 to 0.13.1 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-exporter-prometheus-v0.13.0...metrics-v0.13.1) Updates `indicatif` from 0.17.7 to 0.17.8 - [Release notes](https://github.com/console-rs/indicatif/releases) - [Commits](https://github.com/console-rs/indicatif/commits) Updates `tempfile` from 3.9.0 to 3.10.0 - [Changelog](https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md) - [Commits](https://github.com/Stebalien/tempfile/compare/v3.9.0...v3.10.0) Updates `tonic` from 0.10.2 to 0.11.0 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.2...v0.11.0) Updates `tonic-build` from 0.10.2 to 0.11.0 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.2...v0.11.0) Updates `x25519-dalek` from 2.0.0 to 2.0.1 - [Release notes](https://github.com/dalek-cryptography/curve25519-dalek/releases) - [Commits](https://github.com/dalek-cryptography/curve25519-dalek/compare/2.0.0...x25519-2.0.1) Updates `serde_with` from 3.6.0 to 3.6.1 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.6.0...v3.6.1) --- updated-dependencies: - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: chrono dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: thiserror dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: num-integer dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics-exporter-prometheus dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indicatif dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tempfile dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: tonic dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: tonic-build dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: x25519-dalek dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> * update deny.toml * update deny.toml missing dup --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com>
2024-02-14 04:24:33 -08:00
chrono = { version = "0.4.34", default-features = false, features = ["clock", "std"] }
build(deps): bump the prod group with 6 updates (#8125) * build(deps): bump the prod group with 6 updates Bumps the prod group with 6 updates: | Package | From | To | | --- | --- | --- | | [futures](https://github.com/rust-lang/futures-rs) | `0.3.29` | `0.3.30` | | [tokio](https://github.com/tokio-rs/tokio) | `1.35.0` | `1.35.1` | | [metrics](https://github.com/metrics-rs/metrics) | `0.21.1` | `0.22.0` | | [metrics-exporter-prometheus](https://github.com/metrics-rs/metrics) | `0.12.2` | `0.13.0` | | [reqwest](https://github.com/seanmonstar/reqwest) | `0.11.22` | `0.11.23` | | [owo-colors](https://github.com/jam1garner/owo-colors) | `3.5.0` | `4.0.0` | Updates `futures` from 0.3.29 to 0.3.30 - [Release notes](https://github.com/rust-lang/futures-rs/releases) - [Changelog](https://github.com/rust-lang/futures-rs/blob/master/CHANGELOG.md) - [Commits](https://github.com/rust-lang/futures-rs/compare/0.3.29...0.3.30) Updates `tokio` from 1.35.0 to 1.35.1 - [Release notes](https://github.com/tokio-rs/tokio/releases) - [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.35.0...tokio-1.35.1) Updates `metrics` from 0.21.1 to 0.22.0 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-v0.21.1...metrics-v0.22.0) Updates `metrics-exporter-prometheus` from 0.12.2 to 0.13.0 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-exporter-prometheus-v0.12.2...metrics-exporter-prometheus-v0.13.0) Updates `reqwest` from 0.11.22 to 0.11.23 - [Release notes](https://github.com/seanmonstar/reqwest/releases) - [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md) - [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.22...v0.11.23) Updates `owo-colors` from 3.5.0 to 4.0.0 - [Commits](https://github.com/jam1garner/owo-colors/compare/v3.5.0...v4.0.0) --- updated-dependencies: - dependency-name: futures dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tokio dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: metrics-exporter-prometheus dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: reqwest dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: owo-colors dependency-type: direct:production update-type: version-update:semver-major dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> * update all metric macros * fix deprecated function * fix duplicated deps * Fix an incorrect gauge method call * Expand documentation and error messages for best chain length --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com> Co-authored-by: teor <teor@riseup.net>
2024-01-01 17:26:54 -08:00
futures = "0.3.30"
feature(rpc): add an rpc server to Zebra (#3589) * feature(rpc): add an rpc component * feat(rpc): add a stub for getblockchaininfo This is the first RPC used by lightwalletd, so we need it for testing. * fix(rpc): remove non-standard "jsonrpc: 1.0" from lightwalletd * fix(rpc): re-enable default RPC security checks * deps(rpc): remove not needed dependency * fix(rpc): check if RPC task has stopped * fix(rpc): reduce config by using Option * fix(rpc): use tokio executor * security(rpc): turn off rpc by default * docs(rpc): update a TODO comment Co-authored-by: teor <teor@riseup.net> * fix(rpc): blocking tasks Co-authored-by: teor <teor@riseup.net> * rename(rpc): rpc.rs to methods.rs * refactor(rpc): move the server to the zebra-rpc crate * fix(rpc): clippy derive Default for RPC Config * fix(dependencies): remove unused dependency features in zebra-rpc We expect to use all the listed tokio features to implement and test RPC methods. * doc(rpc): fix testnet port, add security note * fix(rpc): change Rust function names and update method doc TODOs * fix(rpc): add "TODO" to fake RPC responses * doc(rpc): update module docs * fix(rpc): simplify server struct derives * fix(rpc): simplify server code * doc(rpc): explain how request fixes securely handle user-supplied data * refactor(rpc): move the compatibility fix to a separate module * fix(rpc): move the open log inside the spawn, and instrument it * doc(rpc): fix toml format and provide a config example Co-authored-by: teor <teor@riseup.net>
2022-02-22 03:26:29 -08:00
# lightwalletd sends JSON-RPC requests over HTTP 1.1
build(deps): bump the prod group with 4 updates (#8117) Bumps the prod group with 4 updates: [thiserror](https://github.com/dtolnay/thiserror), [sentry](https://github.com/getsentry/sentry-rust), [hyper](https://github.com/hyperium/hyper) and [metrics-exporter-prometheus](https://github.com/metrics-rs/metrics). Updates `thiserror` from 1.0.50 to 1.0.51 - [Release notes](https://github.com/dtolnay/thiserror/releases) - [Commits](https://github.com/dtolnay/thiserror/compare/1.0.50...1.0.51) Updates `sentry` from 0.32.0 to 0.32.1 - [Release notes](https://github.com/getsentry/sentry-rust/releases) - [Changelog](https://github.com/getsentry/sentry-rust/blob/master/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-rust/compare/0.32.0...0.32.1) Updates `hyper` from 0.14.27 to 0.14.28 - [Release notes](https://github.com/hyperium/hyper/releases) - [Changelog](https://github.com/hyperium/hyper/blob/v0.14.28/CHANGELOG.md) - [Commits](https://github.com/hyperium/hyper/compare/v0.14.27...v0.14.28) Updates `metrics-exporter-prometheus` from 0.12.1 to 0.12.2 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/commits) --- updated-dependencies: - dependency-name: thiserror dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: sentry dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: hyper dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics-exporter-prometheus dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-12-18 14:03:41 -08:00
hyper = { version = "0.14.28", features = ["http1", "server"] }
feature(rpc): add an rpc server to Zebra (#3589) * feature(rpc): add an rpc component * feat(rpc): add a stub for getblockchaininfo This is the first RPC used by lightwalletd, so we need it for testing. * fix(rpc): remove non-standard "jsonrpc: 1.0" from lightwalletd * fix(rpc): re-enable default RPC security checks * deps(rpc): remove not needed dependency * fix(rpc): check if RPC task has stopped * fix(rpc): reduce config by using Option * fix(rpc): use tokio executor * security(rpc): turn off rpc by default * docs(rpc): update a TODO comment Co-authored-by: teor <teor@riseup.net> * fix(rpc): blocking tasks Co-authored-by: teor <teor@riseup.net> * rename(rpc): rpc.rs to methods.rs * refactor(rpc): move the server to the zebra-rpc crate * fix(rpc): clippy derive Default for RPC Config * fix(dependencies): remove unused dependency features in zebra-rpc We expect to use all the listed tokio features to implement and test RPC methods. * doc(rpc): fix testnet port, add security note * fix(rpc): change Rust function names and update method doc TODOs * fix(rpc): add "TODO" to fake RPC responses * doc(rpc): update module docs * fix(rpc): simplify server struct derives * fix(rpc): simplify server code * doc(rpc): explain how request fixes securely handle user-supplied data * refactor(rpc): move the compatibility fix to a separate module * fix(rpc): move the open log inside the spawn, and instrument it * doc(rpc): fix toml format and provide a config example Co-authored-by: teor <teor@riseup.net>
2022-02-22 03:26:29 -08:00
jsonrpc-core = "18.0.0"
jsonrpc-derive = "18.0.0"
jsonrpc-http-server = "18.0.0"
feat(rpc): Implement `getblockchaininfo` RPC method (#3891) * Implement `getblockchaininfo` RPC method * add a test for `get_blockchain_info` * fix tohex/fromhex * move comment * Update lightwalletd acceptance test for getblockchaininfo RPC (#3914) * change(rpc): Return getblockchaininfo network upgrades in height order (#3915) * Update lightwalletd acceptance test for getblockchaininfo RPC * Update some doc comments for network upgrades * List network upgrades in order in the getblockchaininfo RPC Also: - Use a constant for the "missing consensus branch ID" RPC value - Simplify fetching consensus branch IDs - Make RPC type derives consistent - Update RPC type documentation * Make RPC type derives consistent * Fix a confusing test comment * get hashand height at the same time * fix estimated_height * fix lint * add extra check Co-authored-by: Janito Vaqueiro Ferreira Filho <janito.vff@gmail.com> * fix typo Co-authored-by: Janito Vaqueiro Ferreira Filho <janito.vff@gmail.com> * split test Co-authored-by: Janito Vaqueiro Ferreira Filho <janito.vff@gmail.com> * fix(rpc): ignore an expected error in the RPC acceptance tests (#3961) * Add ignored regexes to test command failure regex methods * Ignore empty chain error in getblockchaininfo We expect this error when zebrad starts up with an empty state. Co-authored-by: teor <teor@riseup.net> Co-authored-by: Janito Vaqueiro Ferreira Filho <janito.vff@gmail.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2022-03-25 05:25:31 -07:00
# zebra-rpc needs the preserve_order feature in serde_json, which is a dependency of jsonrpc-core
build(deps): bump the prod group with 7 updates (#8208) * build(deps): bump the prod group with 7 updates Bumps the prod group with 7 updates: | Package | From | To | | --- | --- | --- | | [chrono](https://github.com/chronotope/chrono) | `0.4.32` | `0.4.33` | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.1.0` | `2.2.1` | | [serde](https://github.com/serde-rs/serde) | `1.0.195` | `1.0.196` | | [pin-project](https://github.com/taiki-e/pin-project) | `1.1.3` | `1.1.4` | | [serde_json](https://github.com/serde-rs/json) | `1.0.111` | `1.0.113` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.5.0` | `3.5.1` | | [itertools](https://github.com/rust-itertools/itertools) | `0.12.0` | `0.12.1` | Updates `chrono` from 0.4.32 to 0.4.33 - [Release notes](https://github.com/chronotope/chrono/releases) - [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md) - [Commits](https://github.com/chronotope/chrono/compare/v0.4.32...v0.4.33) Updates `indexmap` from 2.1.0 to 2.2.1 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.1.0...2.2.1) Updates `serde` from 1.0.195 to 1.0.196 - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.195...v1.0.196) Updates `pin-project` from 1.1.3 to 1.1.4 - [Release notes](https://github.com/taiki-e/pin-project/releases) - [Changelog](https://github.com/taiki-e/pin-project/blob/main/CHANGELOG.md) - [Commits](https://github.com/taiki-e/pin-project/compare/v1.1.3...v1.1.4) Updates `serde_json` from 1.0.111 to 1.0.113 - [Release notes](https://github.com/serde-rs/json/releases) - [Commits](https://github.com/serde-rs/json/compare/v1.0.111...v1.0.113) Updates `serde_with` from 3.5.0 to 3.5.1 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.5.0...v3.5.1) Updates `itertools` from 0.12.0 to 0.12.1 - [Changelog](https://github.com/rust-itertools/itertools/blob/master/CHANGELOG.md) - [Commits](https://github.com/rust-itertools/itertools/compare/v0.12.0...v0.12.1) --- updated-dependencies: - dependency-name: chrono dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: serde dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: pin-project dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_json dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: itertools dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> * replaces call to deprecated `IndexMap::remove()` with `swap_remove` --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Arya <aryasolhi@gmail.com>
2024-01-30 06:00:28 -08:00
serde_json = { version = "1.0.113", features = ["preserve_order"] }
build(deps): bump the prod group with 14 updates (#8264) * build(deps): bump the prod group with 14 updates Bumps the prod group with 14 updates: | Package | From | To | | --- | --- | --- | | [clap](https://github.com/clap-rs/clap) | `4.4.18` | `4.5.0` | | [chrono](https://github.com/chronotope/chrono) | `0.4.33` | `0.4.34` | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.2.2` | `2.2.3` | | [toml](https://github.com/toml-rs/toml) | `0.8.9` | `0.8.10` | | [thiserror](https://github.com/dtolnay/thiserror) | `1.0.56` | `1.0.57` | | [metrics](https://github.com/metrics-rs/metrics) | `0.22.0` | `0.22.1` | | [num-integer](https://github.com/rust-num/num-integer) | `0.1.45` | `0.1.46` | | [metrics-exporter-prometheus](https://github.com/metrics-rs/metrics) | `0.13.0` | `0.13.1` | | [indicatif](https://github.com/console-rs/indicatif) | `0.17.7` | `0.17.8` | | [tempfile](https://github.com/Stebalien/tempfile) | `3.9.0` | `3.10.0` | | [tonic](https://github.com/hyperium/tonic) | `0.10.2` | `0.11.0` | | [tonic-build](https://github.com/hyperium/tonic) | `0.10.2` | `0.11.0` | | [x25519-dalek](https://github.com/dalek-cryptography/curve25519-dalek) | `2.0.0` | `2.0.1` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.6.0` | `3.6.1` | Updates `clap` from 4.4.18 to 4.5.0 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.4.18...clap_complete-v4.5.0) Updates `chrono` from 0.4.33 to 0.4.34 - [Release notes](https://github.com/chronotope/chrono/releases) - [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md) - [Commits](https://github.com/chronotope/chrono/compare/v0.4.33...v0.4.34) Updates `indexmap` from 2.2.2 to 2.2.3 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.2...2.2.3) Updates `toml` from 0.8.9 to 0.8.10 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.9...toml-v0.8.10) Updates `thiserror` from 1.0.56 to 1.0.57 - [Release notes](https://github.com/dtolnay/thiserror/releases) - [Commits](https://github.com/dtolnay/thiserror/compare/1.0.56...1.0.57) Updates `metrics` from 0.22.0 to 0.22.1 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-v0.22.0...metrics-v0.22.1) Updates `num-integer` from 0.1.45 to 0.1.46 - [Changelog](https://github.com/rust-num/num-integer/blob/master/RELEASES.md) - [Commits](https://github.com/rust-num/num-integer/compare/num-integer-0.1.45...num-integer-0.1.46) Updates `metrics-exporter-prometheus` from 0.13.0 to 0.13.1 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-exporter-prometheus-v0.13.0...metrics-v0.13.1) Updates `indicatif` from 0.17.7 to 0.17.8 - [Release notes](https://github.com/console-rs/indicatif/releases) - [Commits](https://github.com/console-rs/indicatif/commits) Updates `tempfile` from 3.9.0 to 3.10.0 - [Changelog](https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md) - [Commits](https://github.com/Stebalien/tempfile/compare/v3.9.0...v3.10.0) Updates `tonic` from 0.10.2 to 0.11.0 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.2...v0.11.0) Updates `tonic-build` from 0.10.2 to 0.11.0 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.2...v0.11.0) Updates `x25519-dalek` from 2.0.0 to 2.0.1 - [Release notes](https://github.com/dalek-cryptography/curve25519-dalek/releases) - [Commits](https://github.com/dalek-cryptography/curve25519-dalek/compare/2.0.0...x25519-2.0.1) Updates `serde_with` from 3.6.0 to 3.6.1 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.6.0...v3.6.1) --- updated-dependencies: - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: chrono dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: thiserror dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: num-integer dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics-exporter-prometheus dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indicatif dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tempfile dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: tonic dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: tonic-build dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: x25519-dalek dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> * update deny.toml * update deny.toml missing dup --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com>
2024-02-14 04:24:33 -08:00
indexmap = { version = "2.2.3", features = ["serde"] }
feature(rpc): add an rpc server to Zebra (#3589) * feature(rpc): add an rpc component * feat(rpc): add a stub for getblockchaininfo This is the first RPC used by lightwalletd, so we need it for testing. * fix(rpc): remove non-standard "jsonrpc: 1.0" from lightwalletd * fix(rpc): re-enable default RPC security checks * deps(rpc): remove not needed dependency * fix(rpc): check if RPC task has stopped * fix(rpc): reduce config by using Option * fix(rpc): use tokio executor * security(rpc): turn off rpc by default * docs(rpc): update a TODO comment Co-authored-by: teor <teor@riseup.net> * fix(rpc): blocking tasks Co-authored-by: teor <teor@riseup.net> * rename(rpc): rpc.rs to methods.rs * refactor(rpc): move the server to the zebra-rpc crate * fix(rpc): clippy derive Default for RPC Config * fix(dependencies): remove unused dependency features in zebra-rpc We expect to use all the listed tokio features to implement and test RPC methods. * doc(rpc): fix testnet port, add security note * fix(rpc): change Rust function names and update method doc TODOs * fix(rpc): add "TODO" to fake RPC responses * doc(rpc): update module docs * fix(rpc): simplify server struct derives * fix(rpc): simplify server code * doc(rpc): explain how request fixes securely handle user-supplied data * refactor(rpc): move the compatibility fix to a separate module * fix(rpc): move the open log inside the spawn, and instrument it * doc(rpc): fix toml format and provide a config example Co-authored-by: teor <teor@riseup.net>
2022-02-22 03:26:29 -08:00
build(deps): bump the prod group with 6 updates (#8230) Bumps the prod group with 6 updates: | Package | From | To | | --- | --- | --- | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.2.1` | `2.2.2` | | [toml](https://github.com/toml-rs/toml) | `0.8.8` | `0.8.9` | | [tokio](https://github.com/tokio-rs/tokio) | `1.35.1` | `1.36.0` | | [sentry](https://github.com/getsentry/sentry-rust) | `0.32.1` | `0.32.2` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.5.1` | `3.6.0` | | [reqwest](https://github.com/seanmonstar/reqwest) | `0.11.23` | `0.11.24` | Updates `indexmap` from 2.2.1 to 2.2.2 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.1...2.2.2) Updates `toml` from 0.8.8 to 0.8.9 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.8...toml-v0.8.9) Updates `tokio` from 1.35.1 to 1.36.0 - [Release notes](https://github.com/tokio-rs/tokio/releases) - [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.35.1...tokio-1.36.0) Updates `sentry` from 0.32.1 to 0.32.2 - [Release notes](https://github.com/getsentry/sentry-rust/releases) - [Changelog](https://github.com/getsentry/sentry-rust/blob/master/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-rust/compare/0.32.1...0.32.2) Updates `serde_with` from 3.5.1 to 3.6.0 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.5.1...v3.6.0) Updates `reqwest` from 0.11.23 to 0.11.24 - [Release notes](https://github.com/seanmonstar/reqwest/releases) - [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md) - [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.23...v0.11.24) --- updated-dependencies: - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tokio dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: sentry dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: reqwest dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-06 19:18:52 -08:00
tokio = { version = "1.36.0", features = ["time", "rt-multi-thread", "macros", "tracing"] }
tower = "0.4.13"
feature(rpc): add an rpc server to Zebra (#3589) * feature(rpc): add an rpc component * feat(rpc): add a stub for getblockchaininfo This is the first RPC used by lightwalletd, so we need it for testing. * fix(rpc): remove non-standard "jsonrpc: 1.0" from lightwalletd * fix(rpc): re-enable default RPC security checks * deps(rpc): remove not needed dependency * fix(rpc): check if RPC task has stopped * fix(rpc): reduce config by using Option * fix(rpc): use tokio executor * security(rpc): turn off rpc by default * docs(rpc): update a TODO comment Co-authored-by: teor <teor@riseup.net> * fix(rpc): blocking tasks Co-authored-by: teor <teor@riseup.net> * rename(rpc): rpc.rs to methods.rs * refactor(rpc): move the server to the zebra-rpc crate * fix(rpc): clippy derive Default for RPC Config * fix(dependencies): remove unused dependency features in zebra-rpc We expect to use all the listed tokio features to implement and test RPC methods. * doc(rpc): fix testnet port, add security note * fix(rpc): change Rust function names and update method doc TODOs * fix(rpc): add "TODO" to fake RPC responses * doc(rpc): update module docs * fix(rpc): simplify server struct derives * fix(rpc): simplify server code * doc(rpc): explain how request fixes securely handle user-supplied data * refactor(rpc): move the compatibility fix to a separate module * fix(rpc): move the open log inside the spawn, and instrument it * doc(rpc): fix toml format and provide a config example Co-authored-by: teor <teor@riseup.net>
2022-02-22 03:26:29 -08:00
tracing = "0.1.39"
feature(rpc): add an rpc server to Zebra (#3589) * feature(rpc): add an rpc component * feat(rpc): add a stub for getblockchaininfo This is the first RPC used by lightwalletd, so we need it for testing. * fix(rpc): remove non-standard "jsonrpc: 1.0" from lightwalletd * fix(rpc): re-enable default RPC security checks * deps(rpc): remove not needed dependency * fix(rpc): check if RPC task has stopped * fix(rpc): reduce config by using Option * fix(rpc): use tokio executor * security(rpc): turn off rpc by default * docs(rpc): update a TODO comment Co-authored-by: teor <teor@riseup.net> * fix(rpc): blocking tasks Co-authored-by: teor <teor@riseup.net> * rename(rpc): rpc.rs to methods.rs * refactor(rpc): move the server to the zebra-rpc crate * fix(rpc): clippy derive Default for RPC Config * fix(dependencies): remove unused dependency features in zebra-rpc We expect to use all the listed tokio features to implement and test RPC methods. * doc(rpc): fix testnet port, add security note * fix(rpc): change Rust function names and update method doc TODOs * fix(rpc): add "TODO" to fake RPC responses * doc(rpc): update module docs * fix(rpc): simplify server struct derives * fix(rpc): simplify server code * doc(rpc): explain how request fixes securely handle user-supplied data * refactor(rpc): move the compatibility fix to a separate module * fix(rpc): move the open log inside the spawn, and instrument it * doc(rpc): fix toml format and provide a config example Co-authored-by: teor <teor@riseup.net>
2022-02-22 03:26:29 -08:00
Refactor `SentTransactionHash` to be a stricter type (#3706) * Stub `sendrawtransaction` RPC method Register the RPC method, and stub an implementation that currently just panics. The method has a single `String` parameter with the hexadecimal string of the raw transaction's bytes and returns a `SentTransactionHash` wrapper type that's just a hexadecimal `String` of the sent transaction's hash. * Add mempool service instance to `RpcImpl` Use a type parameter to represent the mempool service using the interface defined by `zebra-node-services`. * Update test vector to use a mock mempool service Update the test to be compatible with the changes to `RpcImpl`. The mock mempool service is expected to not be used during the test. * Use a `tower::Buffer` for the mempool service Make it simpler to send requests to the service in a concurrent manner. * Return a `Future` from `send_raw_transaction` Make the call asynchronous. * Implement `sendrawtransaction` RPC Deserialize the transaction and send it to be queued for verification and subsequent inclusion in the mempool. * Test if mempool receives sent raw transaction Use a mock service as the mempool service and check that it receives a sent raw transaction. * Test using non-hexadecimal string parameter The method should return an error. * Test with bytes that fail deserialization Check that the method returns an invalid parameters error if the input can't be deserialized as a `Transaction`. * Test if mempool errors are forwarded to caller Mempool service errors should be sent back to the remote caller as server errors. * Test transactions rejected by the mempool service Transactions that are rejected by the mempool service should result in a server error being sent to the caller. * Improve error message Add the word "structurally" to make it clear that the issue is in the transaction's deserialization. Co-authored-by: Deirdre Connolly <durumcrustulum@gmail.com> * Add note regarding missing `allowhighfees` param. The parameter isn't supported yet because `lightwalletd` doesn't use it. * Update the documentation to be consistent Follow the convention adopted by the `get_info` RPC method. * Implement `ToHex` and `FromHex` for `Hash` Make it easier to generate hexadecimal strings from `transaction::Hash` instances. * Use `ToHex` in `Debug` and `Display` Reduce repeated code. * Refactor to add `bytes_in_display_order` method Use it to remove repeated code and improve clarity a bit. * Use `hex::serialize` to serialize transaction hash Make the type stricter in its contents, while still serializing the transaction has as a hexadecimal string. * Simplify serialization attribute Deserialization should also use `hex::deserialize`, so using the shorter attribute makes things easier to read and more future proof. * Update zebra-chain/src/transaction/hash.rs * Remove unnecessary lifetime The anonymous lifetime is automatically inferred by the compiler. Co-authored-by: Deirdre Connolly <durumcrustulum@gmail.com>
2022-03-08 01:14:21 -08:00
hex = { version = "0.4.3", features = ["serde"] }
build(deps): bump the prod group with 7 updates (#8208) * build(deps): bump the prod group with 7 updates Bumps the prod group with 7 updates: | Package | From | To | | --- | --- | --- | | [chrono](https://github.com/chronotope/chrono) | `0.4.32` | `0.4.33` | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.1.0` | `2.2.1` | | [serde](https://github.com/serde-rs/serde) | `1.0.195` | `1.0.196` | | [pin-project](https://github.com/taiki-e/pin-project) | `1.1.3` | `1.1.4` | | [serde_json](https://github.com/serde-rs/json) | `1.0.111` | `1.0.113` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.5.0` | `3.5.1` | | [itertools](https://github.com/rust-itertools/itertools) | `0.12.0` | `0.12.1` | Updates `chrono` from 0.4.32 to 0.4.33 - [Release notes](https://github.com/chronotope/chrono/releases) - [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md) - [Commits](https://github.com/chronotope/chrono/compare/v0.4.32...v0.4.33) Updates `indexmap` from 2.1.0 to 2.2.1 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.1.0...2.2.1) Updates `serde` from 1.0.195 to 1.0.196 - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.195...v1.0.196) Updates `pin-project` from 1.1.3 to 1.1.4 - [Release notes](https://github.com/taiki-e/pin-project/releases) - [Changelog](https://github.com/taiki-e/pin-project/blob/main/CHANGELOG.md) - [Commits](https://github.com/taiki-e/pin-project/compare/v1.1.3...v1.1.4) Updates `serde_json` from 1.0.111 to 1.0.113 - [Release notes](https://github.com/serde-rs/json/releases) - [Commits](https://github.com/serde-rs/json/compare/v1.0.111...v1.0.113) Updates `serde_with` from 3.5.0 to 3.5.1 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.5.0...v3.5.1) Updates `itertools` from 0.12.0 to 0.12.1 - [Changelog](https://github.com/rust-itertools/itertools/blob/master/CHANGELOG.md) - [Commits](https://github.com/rust-itertools/itertools/compare/v0.12.0...v0.12.1) --- updated-dependencies: - dependency-name: chrono dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: serde dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: pin-project dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_json dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: itertools dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> * replaces call to deprecated `IndexMap::remove()` with `swap_remove` --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Arya <aryasolhi@gmail.com>
2024-01-30 06:00:28 -08:00
serde = { version = "1.0.196", features = ["serde_derive"] }
# Experimental feature getblocktemplate-rpcs
rand = { version = "0.8.5", optional = true }
# ECC deps used by getblocktemplate-rpcs feature
zcash_address = { version = "0.3.1", optional = true }
# Test-only feature proptest-impl
build(deps): bump the prod group with 7 updates (#7938) Bumps the prod group with 7 updates: | Package | From | To | | --- | --- | --- | | [clap](https://github.com/clap-rs/clap) | `4.4.7` | `4.4.8` | | [serde](https://github.com/serde-rs/serde) | `1.0.190` | `1.0.192` | | [toml](https://github.com/toml-rs/toml) | `0.8.6` | `0.8.8` | | [tokio](https://github.com/tokio-rs/tokio) | `1.33.0` | `1.34.0` | | [sentry](https://github.com/getsentry/sentry-rust) | `0.31.7` | `0.31.8` | | [inferno](https://github.com/jonhoo/inferno) | `0.11.17` | `0.11.18` | | [proptest](https://github.com/proptest-rs/proptest) | `1.3.1` | `1.4.0` | Updates `clap` from 4.4.7 to 4.4.8 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.4.7...v4.4.8) Updates `serde` from 1.0.190 to 1.0.192 - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.190...v1.0.192) Updates `toml` from 0.8.6 to 0.8.8 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.6...toml-v0.8.8) Updates `tokio` from 1.33.0 to 1.34.0 - [Release notes](https://github.com/tokio-rs/tokio/releases) - [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.33.0...tokio-1.34.0) Updates `sentry` from 0.31.7 to 0.31.8 - [Release notes](https://github.com/getsentry/sentry-rust/releases) - [Changelog](https://github.com/getsentry/sentry-rust/blob/master/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-rust/compare/0.31.7...0.31.8) Updates `inferno` from 0.11.17 to 0.11.18 - [Changelog](https://github.com/jonhoo/inferno/blob/main/CHANGELOG.md) - [Commits](https://github.com/jonhoo/inferno/compare/v0.11.17...v0.11.18) Updates `proptest` from 1.3.1 to 1.4.0 - [Release notes](https://github.com/proptest-rs/proptest/releases) - [Changelog](https://github.com/proptest-rs/proptest/blob/master/CHANGELOG.md) - [Commits](https://github.com/proptest-rs/proptest/compare/v1.3.1...v1.4.0) --- updated-dependencies: - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tokio dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: sentry dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: inferno dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: proptest dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-14 17:03:57 -08:00
proptest = { version = "1.4.0", optional = true }
2024-01-23 12:00:38 -08:00
zebra-chain = { path = "../zebra-chain", version = "1.0.0-beta.34", features = ["json-conversion"] }
zebra-consensus = { path = "../zebra-consensus", version = "1.0.0-beta.34" }
zebra-network = { path = "../zebra-network", version = "1.0.0-beta.34" }
zebra-node-services = { path = "../zebra-node-services", version = "1.0.0-beta.34" }
zebra-script = { path = "../zebra-script", version = "1.0.0-beta.34" }
zebra-state = { path = "../zebra-state", version = "1.0.0-beta.34" }
[dev-dependencies]
build(deps): bump the test group with 4 updates (#7706) Bumps the test group with 4 updates: [proptest](https://github.com/proptest-rs/proptest), [insta](https://github.com/mitsuhiko/insta), [tonic](https://github.com/hyperium/tonic) and [tonic-build](https://github.com/hyperium/tonic). Updates `proptest` from 1.2.0 to 1.3.1 - [Release notes](https://github.com/proptest-rs/proptest/releases) - [Changelog](https://github.com/proptest-rs/proptest/blob/master/CHANGELOG.md) - [Commits](https://github.com/proptest-rs/proptest/compare/v1.2.0...v1.3.1) Updates `insta` from 1.32.0 to 1.33.0 - [Changelog](https://github.com/mitsuhiko/insta/blob/master/CHANGELOG.md) - [Commits](https://github.com/mitsuhiko/insta/compare/1.32.0...1.33.0) Updates `tonic` from 0.10.1 to 0.10.2 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.1...v0.10.2) Updates `tonic-build` from 0.10.1 to 0.10.2 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.1...v0.10.2) --- updated-dependencies: - dependency-name: proptest dependency-type: direct:production update-type: version-update:semver-minor dependency-group: test - dependency-name: insta dependency-type: direct:production update-type: version-update:semver-minor dependency-group: test - dependency-name: tonic dependency-type: direct:production update-type: version-update:semver-patch dependency-group: test - dependency-name: tonic-build dependency-type: direct:production update-type: version-update:semver-patch dependency-group: test ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-09 14:27:12 -07:00
insta = { version = "1.33.0", features = ["redactions", "json", "ron"] }
build(deps): bump the prod group with 7 updates (#7938) Bumps the prod group with 7 updates: | Package | From | To | | --- | --- | --- | | [clap](https://github.com/clap-rs/clap) | `4.4.7` | `4.4.8` | | [serde](https://github.com/serde-rs/serde) | `1.0.190` | `1.0.192` | | [toml](https://github.com/toml-rs/toml) | `0.8.6` | `0.8.8` | | [tokio](https://github.com/tokio-rs/tokio) | `1.33.0` | `1.34.0` | | [sentry](https://github.com/getsentry/sentry-rust) | `0.31.7` | `0.31.8` | | [inferno](https://github.com/jonhoo/inferno) | `0.11.17` | `0.11.18` | | [proptest](https://github.com/proptest-rs/proptest) | `1.3.1` | `1.4.0` | Updates `clap` from 4.4.7 to 4.4.8 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.4.7...v4.4.8) Updates `serde` from 1.0.190 to 1.0.192 - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.190...v1.0.192) Updates `toml` from 0.8.6 to 0.8.8 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.6...toml-v0.8.8) Updates `tokio` from 1.33.0 to 1.34.0 - [Release notes](https://github.com/tokio-rs/tokio/releases) - [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.33.0...tokio-1.34.0) Updates `sentry` from 0.31.7 to 0.31.8 - [Release notes](https://github.com/getsentry/sentry-rust/releases) - [Changelog](https://github.com/getsentry/sentry-rust/blob/master/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-rust/compare/0.31.7...0.31.8) Updates `inferno` from 0.11.17 to 0.11.18 - [Changelog](https://github.com/jonhoo/inferno/blob/main/CHANGELOG.md) - [Commits](https://github.com/jonhoo/inferno/compare/v0.11.17...v0.11.18) Updates `proptest` from 1.3.1 to 1.4.0 - [Release notes](https://github.com/proptest-rs/proptest/releases) - [Changelog](https://github.com/proptest-rs/proptest/blob/master/CHANGELOG.md) - [Commits](https://github.com/proptest-rs/proptest/compare/v1.3.1...v1.4.0) --- updated-dependencies: - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tokio dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: sentry dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: inferno dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: proptest dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-14 17:03:57 -08:00
proptest = "1.4.0"
build(deps): bump the prod group with 14 updates (#8264) * build(deps): bump the prod group with 14 updates Bumps the prod group with 14 updates: | Package | From | To | | --- | --- | --- | | [clap](https://github.com/clap-rs/clap) | `4.4.18` | `4.5.0` | | [chrono](https://github.com/chronotope/chrono) | `0.4.33` | `0.4.34` | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.2.2` | `2.2.3` | | [toml](https://github.com/toml-rs/toml) | `0.8.9` | `0.8.10` | | [thiserror](https://github.com/dtolnay/thiserror) | `1.0.56` | `1.0.57` | | [metrics](https://github.com/metrics-rs/metrics) | `0.22.0` | `0.22.1` | | [num-integer](https://github.com/rust-num/num-integer) | `0.1.45` | `0.1.46` | | [metrics-exporter-prometheus](https://github.com/metrics-rs/metrics) | `0.13.0` | `0.13.1` | | [indicatif](https://github.com/console-rs/indicatif) | `0.17.7` | `0.17.8` | | [tempfile](https://github.com/Stebalien/tempfile) | `3.9.0` | `3.10.0` | | [tonic](https://github.com/hyperium/tonic) | `0.10.2` | `0.11.0` | | [tonic-build](https://github.com/hyperium/tonic) | `0.10.2` | `0.11.0` | | [x25519-dalek](https://github.com/dalek-cryptography/curve25519-dalek) | `2.0.0` | `2.0.1` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.6.0` | `3.6.1` | Updates `clap` from 4.4.18 to 4.5.0 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.4.18...clap_complete-v4.5.0) Updates `chrono` from 0.4.33 to 0.4.34 - [Release notes](https://github.com/chronotope/chrono/releases) - [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md) - [Commits](https://github.com/chronotope/chrono/compare/v0.4.33...v0.4.34) Updates `indexmap` from 2.2.2 to 2.2.3 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.2...2.2.3) Updates `toml` from 0.8.9 to 0.8.10 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.9...toml-v0.8.10) Updates `thiserror` from 1.0.56 to 1.0.57 - [Release notes](https://github.com/dtolnay/thiserror/releases) - [Commits](https://github.com/dtolnay/thiserror/compare/1.0.56...1.0.57) Updates `metrics` from 0.22.0 to 0.22.1 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-v0.22.0...metrics-v0.22.1) Updates `num-integer` from 0.1.45 to 0.1.46 - [Changelog](https://github.com/rust-num/num-integer/blob/master/RELEASES.md) - [Commits](https://github.com/rust-num/num-integer/compare/num-integer-0.1.45...num-integer-0.1.46) Updates `metrics-exporter-prometheus` from 0.13.0 to 0.13.1 - [Changelog](https://github.com/metrics-rs/metrics/blob/main/release.toml) - [Commits](https://github.com/metrics-rs/metrics/compare/metrics-exporter-prometheus-v0.13.0...metrics-v0.13.1) Updates `indicatif` from 0.17.7 to 0.17.8 - [Release notes](https://github.com/console-rs/indicatif/releases) - [Commits](https://github.com/console-rs/indicatif/commits) Updates `tempfile` from 3.9.0 to 3.10.0 - [Changelog](https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md) - [Commits](https://github.com/Stebalien/tempfile/compare/v3.9.0...v3.10.0) Updates `tonic` from 0.10.2 to 0.11.0 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.2...v0.11.0) Updates `tonic-build` from 0.10.2 to 0.11.0 - [Changelog](https://github.com/hyperium/tonic/blob/master/CHANGELOG.md) - [Commits](https://github.com/hyperium/tonic/compare/v0.10.2...v0.11.0) Updates `x25519-dalek` from 2.0.0 to 2.0.1 - [Release notes](https://github.com/dalek-cryptography/curve25519-dalek/releases) - [Commits](https://github.com/dalek-cryptography/curve25519-dalek/compare/2.0.0...x25519-2.0.1) Updates `serde_with` from 3.6.0 to 3.6.1 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.6.0...v3.6.1) --- updated-dependencies: - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: chrono dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: thiserror dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: num-integer dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: metrics-exporter-prometheus dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: indicatif dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tempfile dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: tonic dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: tonic-build dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: x25519-dalek dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> * update deny.toml * update deny.toml missing dup --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com>
2024-02-14 04:24:33 -08:00
thiserror = "1.0.57"
build(deps): bump the prod group with 6 updates (#8230) Bumps the prod group with 6 updates: | Package | From | To | | --- | --- | --- | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.2.1` | `2.2.2` | | [toml](https://github.com/toml-rs/toml) | `0.8.8` | `0.8.9` | | [tokio](https://github.com/tokio-rs/tokio) | `1.35.1` | `1.36.0` | | [sentry](https://github.com/getsentry/sentry-rust) | `0.32.1` | `0.32.2` | | [serde_with](https://github.com/jonasbb/serde_with) | `3.5.1` | `3.6.0` | | [reqwest](https://github.com/seanmonstar/reqwest) | `0.11.23` | `0.11.24` | Updates `indexmap` from 2.2.1 to 2.2.2 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.1...2.2.2) Updates `toml` from 0.8.8 to 0.8.9 - [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.8...toml-v0.8.9) Updates `tokio` from 1.35.1 to 1.36.0 - [Release notes](https://github.com/tokio-rs/tokio/releases) - [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.35.1...tokio-1.36.0) Updates `sentry` from 0.32.1 to 0.32.2 - [Release notes](https://github.com/getsentry/sentry-rust/releases) - [Changelog](https://github.com/getsentry/sentry-rust/blob/master/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-rust/compare/0.32.1...0.32.2) Updates `serde_with` from 3.5.1 to 3.6.0 - [Release notes](https://github.com/jonasbb/serde_with/releases) - [Commits](https://github.com/jonasbb/serde_with/compare/v3.5.1...v3.6.0) Updates `reqwest` from 0.11.23 to 0.11.24 - [Release notes](https://github.com/seanmonstar/reqwest/releases) - [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md) - [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.23...v0.11.24) --- updated-dependencies: - dependency-name: indexmap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: toml dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: tokio dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: sentry dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod - dependency-name: serde_with dependency-type: direct:production update-type: version-update:semver-minor dependency-group: prod - dependency-name: reqwest dependency-type: direct:production update-type: version-update:semver-patch dependency-group: prod ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-06 19:18:52 -08:00
tokio = { version = "1.36.0", features = ["full", "tracing", "test-util"] }
Implement `sendrawtransaction` RPC (#3685) * Stub `sendrawtransaction` RPC method Register the RPC method, and stub an implementation that currently just panics. The method has a single `String` parameter with the hexadecimal string of the raw transaction's bytes and returns a `SentTransactionHash` wrapper type that's just a hexadecimal `String` of the sent transaction's hash. * Add mempool service instance to `RpcImpl` Use a type parameter to represent the mempool service using the interface defined by `zebra-node-services`. * Update test vector to use a mock mempool service Update the test to be compatible with the changes to `RpcImpl`. The mock mempool service is expected to not be used during the test. * Use a `tower::Buffer` for the mempool service Make it simpler to send requests to the service in a concurrent manner. * Return a `Future` from `send_raw_transaction` Make the call asynchronous. * Implement `sendrawtransaction` RPC Deserialize the transaction and send it to be queued for verification and subsequent inclusion in the mempool. * Test if mempool receives sent raw transaction Use a mock service as the mempool service and check that it receives a sent raw transaction. * Test using non-hexadecimal string parameter The method should return an error. * Test with bytes that fail deserialization Check that the method returns an invalid parameters error if the input can't be deserialized as a `Transaction`. * Test if mempool errors are forwarded to caller Mempool service errors should be sent back to the remote caller as server errors. * Test transactions rejected by the mempool service Transactions that are rejected by the mempool service should result in a server error being sent to the caller. * Improve error message Add the word "structurally" to make it clear that the issue is in the transaction's deserialization. Co-authored-by: Deirdre Connolly <durumcrustulum@gmail.com> * Add note regarding missing `allowhighfees` param. The parameter isn't supported yet because `lightwalletd` doesn't use it. * Update the documentation to be consistent Follow the convention adopted by the `get_info` RPC method. * Remove mempool service usage line It contained incomplete information that's not really necessary. Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com> * Fix formatting `rustfmt` was not executed on the file for the previous commit because I had edited it on GitHub. Co-authored-by: Deirdre Connolly <durumcrustulum@gmail.com> Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com>
2022-03-03 23:00:24 -08:00
zebra-chain = { path = "../zebra-chain", features = ["proptest-impl"] }
zebra-consensus = { path = "../zebra-consensus", features = ["proptest-impl"] }
zebra-network = { path = "../zebra-network", features = ["proptest-impl"] }
zebra-state = { path = "../zebra-state", features = ["proptest-impl"] }
zebra-test = { path = "../zebra-test" }