decred / tinydecred

Python tools for Decred
ISC License
27 stars 14 forks source link

txscript: Add pay to PKH and SH argument validation #150

Closed JoeGruffins closed 4 years ago

JoeGruffins commented 4 years ago

rebased

JoeGruffins commented 4 years ago

Removed the redundant payToSSRtxDirect functions.

This also changes payToStake functions to accept hashes instead of addresses. I think this is acceptable because normally these functions are accessed via payToSStx or payToSStxChange. It would probably be good to make one more of these for revocations payToSSRtx to bring this full circle. However the txscript.makeRevocation doesn't currently care about or validate the network it is on, which is, I think, why the "Direct" wording was in the functions.