-
Notifications
You must be signed in to change notification settings - Fork 11
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
Improvements to state synchronization bridge #102
Conversation
cygnusv
commented
Jul 25, 2023
•
edited
Loading
edited
- Some minor improvements to the ETH<->Polygon sync contracts
- Deployment script for new coordinator
scripts/deploy_xchain_test.py
Outdated
root = deploy_eth_contracts(deployer) | ||
child, stake_info = deploy_polygon_contracts(deployer) | ||
child, _ = deploy_polygon_contracts(deployer) | ||
root = deploy_eth_contracts(deployer, child.address, taco_app) |
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 need taco_app? is this the source?
b2a2428
to
3759907
Compare
scripts/deploy_xchain_test.py
Outdated
polygon_child = project.PolygonChild.deploy( | ||
DEPLOYMENTS_CONFIG.get("fx_child"), | ||
stake_info = project.StakeInfo.deploy( | ||
[deployer.address, polygon_child.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.
polygon_child
hasn't been deployed yet - need to set this address later
For both Ethereum Mainnet - Polygon Mainnet and Ethereum Goerli - Polygon Mumbai. See https://wiki.polygon.technology/docs/pos/design/bridge/l1-l2-communication/state-transfer/#prerequisites
Instead of setting the child tunnel with setFxChildTunnel(), which could be prone to front-running.
This way they can grant/revoke updaters, which is useful for testnets, and the admin can revoke themselves if the updaters list is considered final.
Based on the FlatRateFeeModel script
# Parameter defaults | ||
admin = admin or deployer | ||
rate = rate or 1 | ||
timeout = timeout or 60*60 |
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.
To confirm, this is our default ritual timeout which is 1hr.
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 we put those defaults into @click.option(..., defaults=...)
or ape-config.yaml
?
stake_info.stakingProviderFromOperator("0xAe87D865F3A507185656aD0ef52a8E0B9f3d58f8") | ||
) | ||
print( | ||
stake_info.stakingProviderFromOperator("0x3B42d26E19FF860bC4dEbB920DD8caA53F93c600") |
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.
Where are these addresses obtained from?
sender=deployer, | ||
publish=DEPLOYMENTS_CONFIG.get("verify"), | ||
publish=False, |
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.
Should we be getting this value from the config (verify
)? Same for deploy_polygon_contracts
below?
Or is it that we never publish? If so, how come?
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.
Some changes updated in following PR, considering this - LGTM
Merged to |