-
Notifications
You must be signed in to change notification settings - Fork 152
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
Use a minimal proxy for the curation shares ERC20 #505
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #505 +/- ##
==========================================
+ Coverage 91.91% 91.95% +0.03%
==========================================
Files 33 33
Lines 1658 1666 +8
Branches 282 279 -3
==========================================
+ Hits 1524 1532 +8
Misses 134 134
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
ff07ea6
to
40b1da3
Compare
Rebased |
40b1da3
to
1a2a89b
Compare
Great job |
* curation: use a minimal proxy to save gas when minting for first time * curation: use token utils for transfers * tests: remove unnecessary block advance in test * curation: add external function to set token master copy and avoid re-deploy the clone on minting reset * chore: add graph curation master copy token to deployment config
Description
Signal on a subgraph deployment is represented by a subgraph-specific ERC20 token. When signal is minted for a subgraph deployment for the first time, the Curation contract deploys a new ERC20 token. This is costly, about 1.2M gas.
Solution
Use a Minimal Proxy to clone the Signal-ERC20 based on an implementation. First mint goes from 1,230,118 gas to 432,840