Closed tcharding closed 6 months ago
Before this merges can you confirm please that the new accessor methods fully cover your use case in liquid @apoelstra. Using the new API over there was the last step before we were confident to release this, right?
Yeah, lemme PR to rust-elements to use the new accessors first please.
@tcharding can we do a beta2
release first which includes the new stuff?
Sure thing, I couldn't think of a nice next beta version name yesterday - I'll use beta2
as suggested.
Next beta release done in https://github.com/rust-bitcoin/rust-bech32/pull/169, keeping this here for the v0.10.0
when it comes - can't be far away.
Note the diff includes change to CHANGELOG removing mention of v0.10.0-beta.2
, since we yanked it I believe this is correct.
Ok, sorry, we have to do one more iteration on the API.
The issue I'm having is that there is a specific sequence to parsing a Segwit string:
UncheckedHrpstring
to check that the hrpstring is well-formed (can be done)UncheckedHrpstring::witness_version
) (though in retrospect UncheckedHrpstring::remove_witness_version
I think is useless). Determine the checksum based on the witness version.CheckedHrpstring
(can be done)CheckedHrpstring
(cannot be done)So I think what we want to do is move remove_witness_version
from UncheckedHrpstring
to CheckedHrpstring
and we should be good to go. I suppose it ought to yield the witness version but honestly it doesn't have to, it just be a &mut
method that changes self.data
to self.data[1..]
and doesn't return anything.
But we've made a ton of progress :) on my local rust-elements branch we have
5 files changed, 40 insertions(+), 546 deletions(-)
which is basically all deleted code that I'd copied and tweaked from this library since the API didn't expose enough for me to use it directly.
5 files changed, 40 insertions(+), 546 deletions(-)
That's a win, for sure. Will hack up your suggestions.
I left the functions on UncheckedHrpstring
- from an API perspective seems to be no reason to have them on one and not the other.
ooo yeah, I love waking up in the morning to a fresh release - make my day @apoelstra!
Tagged and published.
Sigh, cargo seems to think that 0.10.0
is the same major rev as 0.10.0-beta
and is breaking downstream crates.
Yanked 0.10.0. Will need to re-release as 0.11.0.
Bother, I wish I came to the same conclusion before I got in a rage about every PR in rust-bitcoin
being broken.
Like, literally the reason we did the -beta
releases ....
In preparation for doing the first "real" (non-beta) release of the new
primitives
module add a changelog entry and bump the version.