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
Add xdai upgrade scripts for chai support #379
Conversation
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.
I don't think it makes sense to keep old upgrade scripts. Let's substitute them by new ones. It will simplify the logic a bit.
If one wants to execute previous upgrade they could use the previous release tags/docker images. What do you think?
Instead of stopping the bridge by changing the limit (extra steps to be coordinated with validators) does it make sense to just roll back the block for |
Yes, I think it is a good idea. I'll remove it
Yes, we can avoid stopping the bridge. Actually, when processing the |
Great! As soon as you finish with preparing new implementation for testing the upgrade please let me know. |
I pushed the changes mentioned. The mcdMigration scripts were removed and also the script to set the daily limit since it is not needed. Also cleaned up the The following steps can be performed to upgrade the bridge:
I'll be testing this and add a comment with the results. |
I tested the upgrade procedure in Sokol-Kovan and it worked correctly, no issues were found. However, I found one issue while testing the Chai integration features. HomeBridge: 0xAEa775BC17BE99B2cd032CE2303b164BC2dC0dDD ForeignBridge: 0xEF3D53Df20aCbB7b742C85d0F8Ca24F480AbE606 Multisig as foreign owner to test the upgrade scripts: 0x6829Df9a24D46f8C2fa22b9c59f9cf30FF49206a Chai: 0x623f148dabd40dd221807c5e98235bc40e54a106 (Used the deployed Chai token mentioned here) Here is the test performed:
In the step One possible fix for this, following how we handle these situations before, could be:
|
Is it necessary to emit a special event in such a case? |
The fix for found issue is being prepared here: #380 |
Closes #377
This PR adds the scripts that can be used in the upgrade of xdai bridge to 4.0.0 release.
The following steps can be performed in order to upgrade the bridge:
HOME_DAILY_LIMIT=0
.env var and runsetHomeDailyLimit
scriptNEW_IMPLEMENTATION_ETH_BRIDGE
.env var and runchaiUpgrade:upgradeBridgeOnForeign
scriptCHAI_INTEREST_RECEIVER
.env var and runchaiUpgrade:initializeChai
scriptHOME_DAILY_LIMIT >= 100000000000000000000001
(maxPerTx
current value is '100000000000000000000000') .env var and run script:setHomeDailyLimit
Stopping the bridge operation from home to foreign is needed in order to ensure processing the transfers correctly since the way how the signatures are executed changes in this new release.
Testing the upgrade is still in-progress. I'll test the upgrade following the mentioned steps and add a comment with the results.