-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Simplify V2FileContractRenewal #238
Conversation
29e6bfc
to
c97ff59
Compare
This looks like it will make rhp4 require setup transactions again for partial rollovers, definitely not worth it imo |
ah. right. drat |
c97ff59
to
cfd6d6b
Compare
cfd6d6b
to
4394f1a
Compare
Unlike the FinalRevision, there is no danger of allowing the new contract to be independently valid, as it cannot be broadcast without also being funded. Note that this is already possible with any other v2 contract formation: anyone can "replay" the contract formation in a transaction of their own, but they need to supply the contract funding themselves.
Instead of a full revision, renewals now specify just the final outputs and rollover amounts. This sidesteps existing inconsistencies around whether the "final revision" should be inserted into the accumulator or not, as well as the issue of the revision being valid in a standalone transaction.
4394f1a
to
6a67c9a
Compare
This PR now makes the following changes:
I believe it's possible for the rollover values to be omitted entirely: the rollover amount can be determined by subtracting the payout values from the original contract value. However, this would require changes to RHPv4, since helpers like |
The tradeoff is that resolution transactions can't contain other outputs. That doesn't seem too restrictive to me, but maybe I'm forgetting a use case that requires it?
I also noticed that a renewal's
FinalRevision
wasn't being applied to the accumulator that way; instead, the accumulator would contain the most recent revision of the contract. Not a huge deal, just felt inconsistent.