-
Notifications
You must be signed in to change notification settings - Fork 41
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
Cross chain arbitrum module #554
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Made ArbitrumTBTC and WormholeGateway upgradable behind OZ transparent proxy Transferred ownership to Governance and Council Transferred ownership from Proxy Admin to Governance
hardhat.config.ts package.json .gitignore yarn.lock
nkuba
reviewed
Mar 30, 2023
cross-chain/arbitrum/deploy_l2/02_deploy_arbitrum_wormhole_gateway.ts
Outdated
Show resolved
Hide resolved
cross-chain/arbitrum/deploy_l2/01_deploy_arbitrum_tbtc_token.ts
Outdated
Show resolved
Hide resolved
cross-chain/arbitrum/deploy_l2/02_deploy_arbitrum_wormhole_gateway.ts
Outdated
Show resolved
Hide resolved
export default func | ||
|
||
func.tags = ["TransferArbitrumTBTCOwnership"] | ||
func.dependencies = ["ArbitrumTBTC"] |
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.
Maybe we should add AuthorizeWormholeGateway
as a dependency to make sure the transfer is executed after the authorization?
nkuba
reviewed
Mar 30, 2023
nkuba
reviewed
Mar 30, 2023
nkuba
reviewed
Mar 30, 2023
Resolved TokenBridge and WormholeTBTC in separate scripts.
- Added L1 and L2 prefixes at the beginning of the env. vars - Commented out companion network because it is not yet used - Added deploy_l1 dir to hardhat network
colon is treated as nested mapping which is not allowed. Removing the colon.
nkuba
reviewed
Mar 30, 2023
cross-chain/arbitrum/deploy_l2/02_deploy_arbitrum_wormhole_gateway.ts
Outdated
Show resolved
Hide resolved
To reduce confusion we prefix wiht arbitrum contracts that are deployed to arbitrum.
Before we overwrite the contract address we ensure it's not set.
We don't have the directory yet, so we don't want to block hardhat network deployment with this entry.
This is consistent with our other projects. The address is resolved based on the private key provided in L1_ACCOUNTS_PRIVATE_KEYS and L2_ACCOUNTS_PRIVATE_KEYS
pdyraga
approved these changes
Mar 31, 2023
pdyraga
dismissed
michalinacienciala’s stale review
March 31, 2023 08:51
@nkuba and @pdyraga took over the review from @michalinacienciala and all her comments were addressed
nkuba
approved these changes
Mar 31, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Part of #542
Depends on the issue #544 with PR #570
Refs #545
This PR creates a new
cross-chain/arbitrum
module to bringtBTC
to L2 Arbitrum with a help of Wormhole. Here's a diagram to illustrate the flowWormhole TokenBridge
on Ethereum - holds allTBTC
bridged to Arbitrum. This is an external contract created by the Wormhole team.Wormhole TokenBridge
on Arbitrum - mints Wormhole wrappedTBTC
ie.wormholeTBTC
. This is an external contract created by the Wormhole team.ArbitrumWormholeGateway
on Arbitrum - acts as a vending machine that wraps and unwrapswormholeTBTC
to the canonicalarbTBTC
token. This is an upgradable Gateway behind OZ transparent proxy. The Threshold team creates it.ArbitrumTBTC
canonicalTBTC
on Arbitrum. It is upgradable behind OZ transparent proxy. The Threshold team creates it.All the ownership of Threshold-created contracts is transferred to the Threshold governance including a proxy admin ownership.
Deploy on Goerli Arbitrum testnet / Arbitrum mainnet
External Wormhole contracts
Wormhole TokenBridge on Goerli Arbitrum
Wormhole TokenBridge on Mainnet Arbitrum
WormholeTBTC on Goerli Arbitrum
WormholeTBTC on Mainnet Arbitrum