-
Notifications
You must be signed in to change notification settings - Fork 1
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
feat: deploy to Linea #18
base: feat/membership
Are you sure you want to change the base?
Conversation
richard-ramos
commented
Oct 1, 2024
•
edited
Loading
edited
- Splits deployment script in separate deployments per contract (since we might want in the future to deploy different PriceCalculators or WakuRLNV2 contracts).
- Adds https://github.com/Cyfrin/foundry-devops to retrieve the latest address deployed. (Useful when using multiple scripts)
- Adds separate package.json scripts to control the deployment of each individual contract
- Setups the deployment for Linea Sepolia
improve terminology consistency and minor refactoring
38181df
to
da65355
Compare
bd9bb06
to
38783cf
Compare
script/Deploy.s.sol
Outdated
|
||
function run() public broadcast returns (address) { | ||
address priceCalcAddr = DevOpsTools.get_most_recent_deployment("LinearPriceCalculator", block.chainid); | ||
address wakuRlnV2ImplAddr = DevOpsTools.get_most_recent_deployment("WakuRlnV2", block.chainid); |
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.
This is cool, but what happens when you don't have a broadcast
directory with a previous deployment on your machine?
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.
Hm, good point.
I'll change the script to allow the usage of environment variables and/or indicate you want to use the broadcast directory.
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.
Change implemented in a5acb1d
Now it will by default use the broadcast dir, unless env variables are used for contracts that were already deployed.
* refactor, minor fixes * do not reset ongoing grace period on extension (cf. spec change) * minor renaming, comments * refactor, group functions by funcitonality * extract membership expiration calculation to internal function * save active duration per membership (must carry over after extension) * optional lazy erasure from membership set * minor fixes in tests * fix: off-by-one: end index can't be equal to next free index * minor refactoring, comments * define period boundaries: start inclusive, end exclusive * separate eraseMembership functions to user-focused (lazy) and admin-focused (tree cleanup) * minor fix to maintain line lengths * unify membership-related events * add test for zero grace period * fix typo in comment Co-authored-by: richΛrd <[email protected]> --------- Co-authored-by: richΛrd <[email protected]>
2b1600a
to
6db38e3
Compare