Skip to content

feat[script]: mainnet deployment #589

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

Merged
merged 12 commits into from
Jun 27, 2024
Merged

feat[script]: mainnet deployment #589

merged 12 commits into from
Jun 27, 2024

Conversation

tserg
Copy link
Collaborator

@tserg tserg commented Jun 21, 2024

This PR adds the deployment script for mainnet.

The differences from devnet and Sepolia are:

  1. The admin address does not transmute any USDC to CASH in the deployment script.
  2. The deployment address transfers admin rights to the multisig, grants the default admin role to the multisig and renounces the default admin role.
  3. A call is made to the Seer to update prices at the end of deployment.

I have manually tested (2) and having the pending admin accept the admin transfer on devnet locally.

A checklist before running the deployment script:

  • Fill in the RPC url for the mainnet profile in scripts/deployment/snfoundry.toml.
  • Fund the admin address with the initial amount of each collateral set out in scripts/src/constants.cairo.

@tserg tserg marked this pull request as ready for review June 26, 2024 08:06
@tserg
Copy link
Collaborator Author

tserg commented Jun 26, 2024

We should also remove MAX_FEE from each call and let sncast estimate it automatically. For cleanliness, I think this is better done in a follow-up PR.

@tserg tserg requested a review from milancermak June 26, 2024 09:20
Copy link
Contributor

@milancermak milancermak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Heh, when reviewing, I realized we'll than have to call accept_admin manually on all modules from the multisig 😬 At least I don't know if there's a way how to do a mutlicall on a multisig.

Does sncast do the fee estimation correctly? Didn't we have a problem with that? FWIW, I think using the MAX_FEE constant is ok.

@tserg
Copy link
Collaborator Author

tserg commented Jun 26, 2024

Heh, when reviewing, I realized we'll than have to call accept_admin manually on all modules from the multisig 😬 At least I don't know if there's a way how to do a mutlicall on a multisig.

I wanted to mention this too but forgot 😄 I did a cursory search earlier in the week and did not see anything related to constructing a multicall for an Argent multisig.

Does sncast do the fee estimation correctly? Didn't we have a problem with that? FWIW, I think using the MAX_FEE constant is ok.

Oh right, we can leave it as it is since it is easy to change MAX_FEE anyway.

@tserg tserg requested a review from milancermak June 27, 2024 08:13
Copy link
Contributor

@milancermak milancermak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tserg tserg merged commit c31e562 into main Jun 27, 2024
1 check passed
@tserg tserg deleted the script/mainnet branch June 27, 2024 09:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants