diff --git a/Cargo.toml b/Cargo.toml index d1c7ddc..9185e95 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,15 +14,15 @@ async = ["dep:async_zmq", "dep:futures-util"] [dependencies] async_zmq = { version = "0.4.0", optional = true } -bitcoin = "0.31.1" -futures-util = { version = "0.3.28", optional = true } +bitcoin = "0.32.0" +futures-util = { version = "0.3.30", optional = true } zmq = "0.10.0" zmq-sys = "0.12.0" # dependencies used in examples [dev-dependencies] -futures = "0.3.28" -tokio = { version = "1.35.0", features = ["time", "rt-multi-thread", "macros"] } +futures = "0.3.30" +tokio = { version = "1.37.0", features = ["time", "rt-multi-thread", "macros"] } [[example]] name = "subscribe_async_timeout" diff --git a/README.md b/README.md index 25794f4..6bff6b9 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,7 @@ Integration tests use the latest version of the 5 most recent major Bitcoin Core TODO: - This README - SequenceMessage itest -- Easy addEventListener like functionality with help of the `getzmqnotifications` rpc (bitcoincore-rpc PR: [#295](https://github.com/rust-bitcoin/rust-bitcoincore-rpc/pull/295)) +- Easy addEventListener like functionality with help of the `getzmqnotifications` rpc - raw messages - zmq publisher - include source in message diff --git a/integration_tests/Cargo.toml b/integration_tests/Cargo.toml index 92f9208..72e855a 100644 --- a/integration_tests/Cargo.toml +++ b/integration_tests/Cargo.toml @@ -4,8 +4,8 @@ version = "1.0.0" edition = "2021" [dependencies] -bitcoin = "0.31.1" -bitcoincore-rpc = "0.18.0" +bitcoin = "0.32.0" +bitcoincore-rpc = "0.19.0" bitcoincore-zmq = { path = "..", features = ["async"] } -futures = "0.3.28" -tokio = { version = "1.35.0", features = ["full"] } +futures = "0.3.30" +tokio = { version = "1.37.0", features = ["full"] } diff --git a/integration_tests/src/main.rs b/integration_tests/src/main.rs index b53cecf..4ea6757 100644 --- a/integration_tests/src/main.rs +++ b/integration_tests/src/main.rs @@ -69,7 +69,7 @@ fn test_hashtx(rpc: &Client) { match recv_timeout_2(&receiver) { (Message::Tx(tx, _), Message::HashTx(txid, _)) | (Message::HashTx(txid, _), Message::Tx(tx, _)) => { - assert_eq!(tx.txid(), txid); + assert_eq!(tx.compute_txid(), txid); } (msg1, msg2) => { panic!("invalid messages received: ({msg1}, {msg2})"); diff --git a/src/message.rs b/src/message.rs index e936b80..f38a728 100644 --- a/src/message.rs +++ b/src/message.rs @@ -181,7 +181,7 @@ impl fmt::Display for Message { Self::HashBlock(blockhash, seq) => write!(f, "HashBlock({blockhash}, sequence={seq})"), Self::HashTx(txid, seq) => write!(f, "HashTx({txid}, sequence={seq})"), Self::Block(block, seq) => write!(f, "Block({}, sequence={seq})", block.block_hash()), - Self::Tx(tx, seq) => write!(f, "Tx({}, sequence={seq})", tx.txid()), + Self::Tx(tx, seq) => write!(f, "Tx({}, sequence={seq})", tx.compute_txid()), Self::Sequence(sm, seq) => write!(f, "Sequence({sm}, sequence={seq})"), } } @@ -198,7 +198,7 @@ mod tests { let tx = &genesis_block.txdata[0]; let tx_bytes = serialize(tx); - let txid = tx.txid(); + let txid = tx.compute_txid(); let mut txid_bytes = txid.to_byte_array(); txid_bytes.reverse(); @@ -241,7 +241,7 @@ mod tests { fn test_deserialize_hashtx() { let genesis_block = genesis_block(Network::Bitcoin); - let txid = genesis_block.txdata[0].txid(); + let txid = genesis_block.txdata[0].compute_txid(); let mut txid_bytes = txid.to_byte_array(); txid_bytes.reverse(); diff --git a/src/sequence_message.rs b/src/sequence_message.rs index a052a6f..00e1da1 100644 --- a/src/sequence_message.rs +++ b/src/sequence_message.rs @@ -202,7 +202,7 @@ mod tests { let mut blockhash_bytes = blockhash.to_byte_array(); blockhash_bytes.reverse(); - let txid = genesis_block.txdata[0].txid(); + let txid = genesis_block.txdata[0].compute_txid(); let mut txid_bytes = txid.to_byte_array(); txid_bytes.reverse();