Closed iamhardikat11 closed 2 months ago
TODO TEMP scripts is just the top root th_branch manually calculated! Done! Please Check
Hi @iamhardikat11
Wrt hex_to_bytes: if hex_to_bytes(..., False) is not called anywhere (which I believe it is the case, but please check) then we can use h_to_b instead and delete hex_to_bytes entirely.
Wrt to calculating the merkle proof I have not checked it in detail yet but I saw that you don't use tagged hashes (see taproot examples, where I manually construct it). Have you run the tests after the change to see if anything breaks?
Hi @karask I have run the tests and then pass on the PR I made. I will try and see to apply the changes you suggested above.
Hi @karask I have removed hex_to_bytes my bad on not checking symbol use, also Can you ping a reference to tagged hashes (see taproot examples, where I manually construct it). I have run the tests on the Branch under my Fork.
Taproot example: https://github.com/karask/python-bitcoin-utils/blob/master/examples/spend_p2tr_three_scripts_by_script_path.py
I'd suggest to remove the merkle proof part and make it a new PR so I can merge separately.
Ok
HI @karask I have removed Merkle Root Proof, you can merge the PR if everything else is fine.
Hi @karask I have done a cleanup task from TODO to remove bytes32_from_int and changed every occurence to i_to_b32. All tests passed.
Just a Bit of Cleaning done in bitcoinutils/utils.py
Solved:- TODO REMOVE --- NOT USED TODO improve by checking if valid, etc. TODO Implement is_address_bech32() TODO name hex_to_bytes ??