Skip to content

Feat: add deploy scripts#9

Merged
happenwah merged 2 commits intoValantisLabs:mainfrom
alphak3y:main
Nov 2, 2024
Merged

Feat: add deploy scripts#9
happenwah merged 2 commits intoValantisLabs:mainfrom
alphak3y:main

Conversation

@alphak3y
Copy link
Copy Markdown
Contributor

@alphak3y alphak3y commented Nov 2, 2024

This PR adds foundry deploy scripts under the scripts/ folder.

Comment thread scripts/base/DeployValidlyBase.sol Outdated
protocolFactory.setSovereignPoolFactory(address(poolFactory));

// Create ValidlyFactory
factory = new ValidlyFactory(address(protocolFactory), 1);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This will always deploy a ValidlyFactory with 1 bips fee tier. Is this intentional, even for volatile pairs? If not, consider making it a function argument

Copy link
Copy Markdown
Contributor Author

@alphak3y alphak3y Nov 2, 2024

Choose a reason for hiding this comment

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

Okay I see a new factory is required for each new fee tier. Thanks for the heads up 👍


poolFactory = new SovereignPoolFactory();

protocolFactory.setSovereignPoolFactory(address(poolFactory));
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

protocol factory and sovereign pool factory only need to be deployed once per chain. Consider this when deploying in production.

@happenwah
Copy link
Copy Markdown
Contributor

Thanks for the first official contribution king

@happenwah happenwah merged commit 9ae4d6c into ValantisLabs:main Nov 2, 2024
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