HomePhabricator

[electrum] clarify the concept of number of sigs in a TxInput

Description

[electrum] clarify the concept of number of sigs in a TxInput

Summary:
The previous num_sig property did not match the coin dict implementation nor its own documentation. The length of the signature list can be more than the required number of signatures for incompletely signed multisig inputs.

Split this into two properties:

  • the number of required signatures
  • the number of provided valid signatures in the signatures list (items that are not None)

The length of the signatures list including None items does not need its own property.

Add a 2-of-3 partially signed transaction test to cover the case for which len(signatures) != num_required_sigs (m != n).

Test Plan: python test_runner.py

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D14483

Details

Provenance
PiRKAuthored on Sep 14 2023, 07:21
PiRKPushed on Sep 14 2023, 15:48
Reviewer
Restricted Project
Differential Revision
D14483: [electrum] clarify the concept of number of sigs in a TxInput
Parents
rABCdd1ff64bb41d: [avalanche] Improve the staking reward proof age selection
Branches
Unknown
Tags
Unknown