Open scravy opened 5 years ago
Update: generate
is correct in that it does create the right reference, but still there is something fishy. The logic proposed in the second code block here still is the logic which should go here. I had played around with passing the reward address and the stake return address separately to control this in https://github.com/dtr-org/unit-e/pull/886 which broke stuff, which should not happen if both were doing the same thing (which apparently they are not).
Anyways, postponing as generate/generatetoaddress are good enough for creating stake validation (All I need for that is the RPCs from #900 to properly assert on the staking state).
generate
andgeneratetoaddress
use a half-baked version of proposing blocks but they should use the proposer logic / block builder components.The code in question is the following:
This code replaces the spending outpoint (!) with the target pubkey.
Using the components ready made for staking the proposing code should read: