mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-20 03:39:48 +02:00
qa: timelock coinbase transactions created in functional tests
This commit is contained in:
@@ -29,6 +29,7 @@ from .messages import (
|
||||
tx_from_hex,
|
||||
uint256_from_compact,
|
||||
WITNESS_SCALE_FACTOR,
|
||||
MAX_SEQUENCE_NONFINAL,
|
||||
)
|
||||
from .script import (
|
||||
CScript,
|
||||
@@ -151,7 +152,8 @@ def create_coinbase(height, pubkey=None, *, script_pubkey=None, extra_output_scr
|
||||
If extra_output_script is given, make a 0-value output to that
|
||||
script. This is useful to pad block weight/sigops as needed. """
|
||||
coinbase = CTransaction()
|
||||
coinbase.vin.append(CTxIn(COutPoint(0, 0xffffffff), script_BIP34_coinbase_height(height), SEQUENCE_FINAL))
|
||||
coinbase.nLockTime = height - 1
|
||||
coinbase.vin.append(CTxIn(COutPoint(0, 0xffffffff), script_BIP34_coinbase_height(height), MAX_SEQUENCE_NONFINAL))
|
||||
coinbaseoutput = CTxOut()
|
||||
coinbaseoutput.nValue = nValue * COIN
|
||||
if nValue == 50:
|
||||
|
||||
Reference in New Issue
Block a user