-
Notifications
You must be signed in to change notification settings - Fork 112
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
Add multicall support to contracts #1091
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
area
force-pushed
the
feat/multicall
branch
2 times, most recently
from
September 30, 2022 15:37
7ca84d2
to
71f2800
Compare
area
force-pushed
the
feat/multicall
branch
5 times, most recently
from
October 12, 2022 12:25
5ff012b
to
52e18fd
Compare
@area is this still a draft? |
area
force-pushed
the
feat/multicall
branch
7 times, most recently
from
October 27, 2022 14:12
0295942
to
a9e4452
Compare
I still don't want this merged quite yet, but good for reviewing. |
kronosapiens
reviewed
Nov 5, 2022
kronosapiens
previously approved these changes
Nov 21, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
kronosapiens
previously approved these changes
Nov 24, 2022
kronosapiens
force-pushed
the
feat/multicall
branch
from
December 2, 2022 01:10
3e41da6
to
c2a37f8
Compare
kronosapiens
approved these changes
Dec 2, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #1058
This PR adds Multicall support to colony contracts - currently just to Colony and ColonyNetwork, but will be added to extensions as well. Looking for a review, but not a merge, at this point.
The multicall functionality allows a single transaction to call multiple functions on the same contract, assuming that all the parameters are know at the time of the call. So, for example, this wouldn't be appropriate for creating an expenditure, and then editing it, because the id of the expenditure is not known at the time of the transaction.
The multicall implementation is from Uniswap, though I've changed it. I've removed payable, to stop us tripping ourselves up in the future.
It also required some changing to allow compatability with metatransactions, which with the default implementation wouldn't work as expected. That's where I'm most interested in getting feedback - as with anything related to metatransactions, that needs to be considered very carefully and has to be right otherwise there will be a lot of problems.
Some changes were also required on the metatransaction broadcaster, as we don't want calls that we otherwise wouldn't pay for being allowed just because they're wrapped inside a multicall (i.e. we don't want to just pay for all multicalls).