-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
USDC token pool changesets (+ token pool patches) #16062
base: develop
Are you sure you want to change the base?
Conversation
} | ||
if rmnProxy := chainState.RMNProxy; rmnProxy == nil { | ||
return fmt.Errorf("missing rmnProxy on %s", chain) | ||
} |
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.
need to check if token address in present in the state?
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.
We don't store the token address in the address book, only the token pool
} | ||
|
||
for chainSelector, poolConfig := range c.NewUSDCPools { | ||
chain := env.Chains[chainSelector] |
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.
can there be a check whether token pool is already deployed with same version for the token address?
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.
That check exists in DeployUSDCTokenPoolInput.Validate
if _, ok := c.USDCConfigsByChain[chainSelector]; !ok && chainState.USDCTokenPools != nil { | ||
return fmt.Errorf("no USDC chain config defined for %s, which does support USDC", env.Chains[chainSelector]) |
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.
what happens if we already have the chain config set up for few USDC chains?
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.
Then there will just be no net action to take for those chains. I think it is best to enforce defining every chain that supports USDC any time we run this command. They all point at each other, so it is best to have the user specify every which USDC versions should be active so that each chain can reference the correct remote pool.
} | ||
|
||
if len(domainUpdates) > 0 { | ||
_, err := usdcTokenPool.SetDomains(writeOpts, domainUpdates) |
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.
validating token pool ownership anywhere?
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.
Yea that check is present in SyncUSDCDomainsWithChainsConfig.Validate
"github.com/smartcontractkit/chainlink/v2/core/logger" | ||
) | ||
|
||
func deployChainWithUSDCTokenPool( |
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.
Do we not already have this in NewEnvironmentWithJobsAndContracts with Testconfig as USDC Deployment set to true?
Will need to rebase this PR against #16140 |
Quality Gate passedIssues Measures |
https://smartcontract-it.atlassian.net/browse/CCIP-4507
This PR adds two new changesets:
It also makes a few patches to token pool utilities and changesets:
Requires
#16140