You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<btcpy.structs.transaction.Transaction object at 0x7f3717971518>
561
+
```
562
+
514
563
Example of a transaction creation:
515
564
516
565
```python
@@ -574,7 +623,7 @@ parameters:
574
623
|`NulldataScript`| An OP_RETURN script | A `StackData` representing the data to store in the transaction |
575
624
|`MultisigScript`| A multisig script, where m out of n keys are needed to spend |`m`, the number of signatures needed to spend this output, an arbitrary number of `PublicKeys`, `n` the number of public keys provided |
576
625
|`IfElseScript`| A script consisting of an `OP_IF`, a script, an `OP_ELSE`, another script and an `OP_ENDIF`| Two `ScriptPubKey` scripts, the first to be executed in the if branch, the second to be executed in the else branch |
577
-
|`TimelockScript`| A script consisting of `<pushdata>OP_CHECKLOCKTIMEVERIFYOP_DROP`and a subsequent script which can be spent only after the absolute time expressed by the `<pushdata>`is expired | A `Locktime`, expressing the absolute time/number of blocks after which the subsequent script can be spent, and the locked `ScriptPubKey`|
626
+
|`AbsoluteTimelockScript`| A script consisting of `<pushdata>OP_CHECKLOCKTIMEVERIFYOP_DROP`and a subsequent script which can be spent only after the absolute time expressed by the `<pushdata>`is expired | A `Locktime`, expressing the absolute time/number of blocks after which the subsequent script can be spent, and the locked `ScriptPubKey`|
578
627
|`RelativeTimelockScript`| A script consisting of `<pushdata>OP_CHECKSEQUENCEVERIFYOP_DROP`and a subsequent script which can be spent only after the relative time time expressed by the `<pushdata>`is expired | A `Sequence`, expressing the relative time/ number of blocks after which the subsequent script can be spent, and the locked `ScriptPubKey`|
579
628
|`Hashlock256Script`| A script consisting of `OP_HASH256<pushdata>OP_EQUALVERIFY`and a subsequent script which can be spent only after providing the preimage of `<pushdata>`for the double SHA256hash function | Either a `bytearray`or`StackData` representing the hashed value that locks the subsequent script, plus the locked `ScriptPubKey`|
580
629
|`Hashlock160Script`| A script consisting of `OP_HASH160<pushdata>OP_EQUALVERIFY`and a subsequent script which can be spent only after providing the preimage of `<pushdata>`for the RIPEMPD160 of the SHA256hash function | Either a `bytearray`or`StackData` representing the hashed value that locks the subsequent script, plus the locked `ScriptPubKey`|
@@ -610,7 +659,9 @@ Additionally, the following solvers are available and they take the following in
610
659
|`P2wshV0Solver`| a `ScriptPubKey`, representing the witnessScript and a `Solver` which solves the inner witnessScript |`P2wshV0Script`|
611
660
|`MultisigSolver`| an arbitrary number of `PrivateKey`s |`MultisigScript`|
612
661
|`IfElseSolver`| an object of type`Branch`. This is an enum and its values are `Branch.IF`and`Branch.ELSE`, these are used to specify whether we are spending the `if`or`else` branch of the script. The second parameter is a `Solver`for the script inside the desired branch. |`IfElseScript`|
613
-
|`TimelockSolver`| a `Solver` of the inner timelocked script |`TimelockedScript`, `RelativeTimelockScript`|
662
+
|`TimelockSolver`| a `Solver` of the inner timelocked script |`AbsoluteTimelockScript`, `RelativeTimelockScript`|
663
+
|`RelativeTimelockSolver`| a `Solver` of the inner timelocked script, with absolute timelocks |`RelativeTimelockScript`|
664
+
|`AbsoluteTimelockSolver`| a `Solver` of the inner timelocked script, with relative timelocks |`AbsoluteTimelockScript`|
614
665
|`HashlockSolver`| the preimage needed to spend the script, as a `bytearray`, and a `Solver`for the hashlocked script |`Hashlock256Script`, `Hashlock160Script`|
615
666
616
667
@@ -820,7 +871,7 @@ Let's write the solvers for this script:
0 commit comments