-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deprecate get_ prefix for Block and Transaction methods #128
Deprecate get_ prefix for Block and Transaction methods #128
Conversation
To match the changes introduced in rust-bitcoin: rust-bitcoin/rust-bitcoin#861
I ran into this in electrs, where I ended up creating an Another incompatibility that I ran into is that rust-bitcoin (as of v0.28) iterates over witness elements as a (Initially I had to use |
@@ -372,17 +372,29 @@ impl Block { | |||
} | |||
|
|||
/// Get the size of the block | |||
#[deprecated(since = "0.19.1", note = "Please use `Block::size` instead.")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This assumes that the next release is going to be 0.19.1
, which might not be the case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK 2a35bad
I'm happy to do a quick point release if you want. There's nothing else in the queue. |
No urgency for me, I can keep using the compatibility trait until a new release is out. Thanks for merging! |
The EBCompact compatibility trait is no longer necessary, the `get` prefix was removed in ElementsProject/rust-elements#128
The EBCompact compatibility trait is no longer necessary, the `get` prefix was removed in ElementsProject/rust-elements#128
To match the changes introduced in rust-bitcoin/rust-bitcoin#861.
This allows using unified code with the same methods for both
elements::{Transaction,Block}
andbitcoin::{Transaction,Block}
(behind different features), without triggering rust-bitcoin's deprecation warnings for theget_
-prefixed methods.Note that there are other instances of
get_
-prefixed methods in the rust-elements codebase. I only updated the ones needed for compatibility with the changes made in rust-bitcoin.