Open raedah opened 4 years ago
The purchaseticket method needs to be replaced with something more flexible. Here is the problem:
$ dcrctl -l | grep purchaseticket
purchaseticket "fromaccount" spendlimit (minconf=1 "ticketaddress" numtickets "pooladdress" poolfees expiry "comment" ticketfee)
There's no place to specify a voting account without also specifying a voting address (which is nonsensical, but could be the empty string), VSP options (which don't support anything but a static voting address, therefore also nonsensical), and an unused comment field.
We can't use the application defaults, because by precedence, this RPC does not use those application options anyways, instead requiring the caller to pass them in each time.
The configured voting account is used when doing coinjoins, but is not used when doing a standard purchaseticket. Expected behavior is for the configured votingaccount to apply to all ticket purchases.