From 0808b780f75a5cffa0a26a160c4cee17078e816b Mon Sep 17 00:00:00 2001 From: Anthony Laibe Date: Mon, 29 Jan 2024 11:15:28 +0100 Subject: [PATCH] feat: add sepolia optimism --- contracts/ethscan/address.go | 1 + multiaccounts/accounts/database.go | 2 +- rpc/network/network.go | 5 ++--- services/wallet/token/tokenstore.go | 8 ++++++++ 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/contracts/ethscan/address.go b/contracts/ethscan/address.go index 6c605b1b1..00d703a90 100644 --- a/contracts/ethscan/address.go +++ b/contracts/ethscan/address.go @@ -23,6 +23,7 @@ var contractDataByChainID = map[uint64]ContractData{ 777333: {common.HexToAddress("0x0000000000000000000000000000000000777333"), 50}, // unit tests 11155111: {common.HexToAddress("0xec21ebe1918e8975fc0cd0c7747d318c00c0acd5"), 4_366_506}, // sepolia 421614: {common.HexToAddress("0xec21Ebe1918E8975FC0CD0c7747D318C00C0aCd5"), 553_947}, // sepolia arbitrum + 11155420: {common.HexToAddress("0xec21ebe1918e8975fc0cd0c7747d318c00c0acd5"), 7_362_011}, // sepolia optimism } func ContractAddress(chainID uint64) (common.Address, error) { diff --git a/multiaccounts/accounts/database.go b/multiaccounts/accounts/database.go index 47ad4f749..f37a3d19b 100644 --- a/multiaccounts/accounts/database.go +++ b/multiaccounts/accounts/database.go @@ -113,7 +113,7 @@ const ( ProdPreferredChainIDsDefault = "1:10:42161" TestPreferredChainIDsDefault = "5:420:421613" - TestSepoliaPreferredChainIDsDefault = "11155111:420:421614" + TestSepoliaPreferredChainIDsDefault = "11155111:11155420:421614" ) // Returns true if an account is a wallet account that logged in user has a control over, otherwise returns false. diff --git a/rpc/network/network.go b/rpc/network/network.go index 929d7c024..876432e71 100644 --- a/rpc/network/network.go +++ b/rpc/network/network.go @@ -9,10 +9,9 @@ import ( "github.com/status-im/status-go/params" ) -var SepoliaChainIDs = []uint64{11155111, 421614} +var SepoliaChainIDs = []uint64{11155111, 421614, 11155420} -// GoerliChainIDs Uncomment next chain when we move more chain to sepolia -var GoerliChainIDs = []uint64{5, 421613} //, 420, } +var GoerliChainIDs = []uint64{5, 421613, 420} type CombinedNetwork struct { Prod *params.Network diff --git a/services/wallet/token/tokenstore.go b/services/wallet/token/tokenstore.go index 9207c14e9..95e273bad 100644 --- a/services/wallet/token/tokenstore.go +++ b/services/wallet/token/tokenstore.go @@ -1696,6 +1696,14 @@ func newDefaultStore() *DefaultStore { ChainID: 421614, TokenListID: "status", }, + &Token{ + Address: common.HexToAddress("0x44a739916D41eC0226d98F83BE5364B69078DA41"), + Name: "USD Coin", + Symbol: "USDC", + Decimals: 6, + ChainID: 11155420, + TokenListID: "status", + }, }, } }