chore_: Remove Goerli code (#21508)
This commit removes the goerli-related code from the mobile repo. Signed-off-by: Mohamed Javid <19339952+smohamedjavid@users.noreply.github.com>
This commit is contained in:
parent
8e7d5233df
commit
9f1eb60e21
1
.env
1
.env
|
@ -1,6 +1,5 @@
|
||||||
CACHED_WEBVIEWS_ENABLED=1
|
CACHED_WEBVIEWS_ENABLED=1
|
||||||
DEBUG_WEBVIEW=1
|
DEBUG_WEBVIEW=1
|
||||||
DEFAULT_NETWORK=mainnet_rpc
|
|
||||||
DEV_BUILD=1
|
DEV_BUILD=1
|
||||||
ETHEREUM_DEV_CLUSTER=1
|
ETHEREUM_DEV_CLUSTER=1
|
||||||
EXTENSIONS=0
|
EXTENSIONS=0
|
||||||
|
|
5
.env.e2e
5
.env.e2e
|
@ -1,5 +1,4 @@
|
||||||
DEBUG_WEBVIEW=1
|
DEBUG_WEBVIEW=1
|
||||||
DEFAULT_NETWORK=goerli_rpc
|
|
||||||
ETHEREUM_DEV_CLUSTER=1
|
ETHEREUM_DEV_CLUSTER=1
|
||||||
EXTENSIONS=0
|
EXTENSIONS=0
|
||||||
FLEET=status.staging
|
FLEET=status.staging
|
||||||
|
@ -22,8 +21,8 @@ KEYCARD_TEST_MENU=1
|
||||||
QR_READ_TEST_MENU=1
|
QR_READ_TEST_MENU=1
|
||||||
ENABLE_ROOT_ALERT=0
|
ENABLE_ROOT_ALERT=0
|
||||||
APN_TOPIC=im.status.ethereum.pr
|
APN_TOPIC=im.status.ethereum.pr
|
||||||
VERIFY_TRANSACTION_CHAIN_ID=5
|
VERIFY_TRANSACTION_CHAIN_ID=11155111
|
||||||
VERIFY_ENS_CHAIN_ID=5
|
VERIFY_ENS_CHAIN_ID=11155111
|
||||||
TEST_STATEOFUS=1
|
TEST_STATEOFUS=1
|
||||||
DATABASE_MANAGEMENT_ENABLED=1
|
DATABASE_MANAGEMENT_ENABLED=1
|
||||||
COMMUNITIES_ENABLED=1
|
COMMUNITIES_ENABLED=1
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
CACHED_WEBVIEWS_ENABLED=1
|
CACHED_WEBVIEWS_ENABLED=1
|
||||||
DEBUG_WEBVIEW=1
|
DEBUG_WEBVIEW=1
|
||||||
DEFAULT_NETWORK=goerli_rpc
|
|
||||||
ETHEREUM_DEV_CLUSTER=1
|
ETHEREUM_DEV_CLUSTER=1
|
||||||
EXTENSIONS=0
|
EXTENSIONS=0
|
||||||
GROUP_CHATS_ENABLED=1
|
GROUP_CHATS_ENABLED=1
|
||||||
|
@ -21,8 +20,8 @@ KEYCARD_TEST_MENU=0
|
||||||
ENABLE_ROOT_ALERT=1
|
ENABLE_ROOT_ALERT=1
|
||||||
DISABLE_WALLET_ON_MOBILE_NETWORK=1
|
DISABLE_WALLET_ON_MOBILE_NETWORK=1
|
||||||
APN_TOPIC=im.status.ethereum.pr
|
APN_TOPIC=im.status.ethereum.pr
|
||||||
VERIFY_TRANSACTION_CHAIN_ID=5
|
VERIFY_TRANSACTION_CHAIN_ID=11155111
|
||||||
VERIFY_ENS_CHAIN_ID=5
|
VERIFY_ENS_CHAIN_ID=11155111
|
||||||
TEST_STATEOFUS=1
|
TEST_STATEOFUS=1
|
||||||
BLANK_PREVIEW=0
|
BLANK_PREVIEW=0
|
||||||
DATABASE_MANAGEMENT_ENABLED=1
|
DATABASE_MANAGEMENT_ENABLED=1
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
DEBUG_WEBVIEW=1
|
DEBUG_WEBVIEW=1
|
||||||
DEFAULT_NETWORK=mainnet_rpc
|
|
||||||
ETHEREUM_DEV_CLUSTER=1
|
ETHEREUM_DEV_CLUSTER=1
|
||||||
EXTENSIONS=0
|
EXTENSIONS=0
|
||||||
GROUP_CHATS_ENABLED=1
|
GROUP_CHATS_ENABLED=1
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
DEBUG_WEBVIEW=0
|
DEBUG_WEBVIEW=0
|
||||||
DEFAULT_NETWORK=mainnet_rpc
|
|
||||||
ETHEREUM_DEV_CLUSTER=0
|
ETHEREUM_DEV_CLUSTER=0
|
||||||
EXTENSIONS=0
|
EXTENSIONS=0
|
||||||
GROUP_CHATS_ENABLED=1
|
GROUP_CHATS_ENABLED=1
|
||||||
|
|
|
@ -92,7 +92,7 @@ For particular example it was failed on `Recover access(password:qwerty, keycard
|
||||||
Not all features of the app could be covered by e2e at the moment:
|
Not all features of the app could be covered by e2e at the moment:
|
||||||
|
|
||||||
- Colours or place of an element on UI.
|
- Colours or place of an element on UI.
|
||||||
- Real ETH/token transactions. That’s the main reason we have separate .apk build for automation needs - it defaults to Goerli network. Also it has enabled keycard test menu, ENS names and chat commands are also on Goerli network (the same in PR builds, but not in nightlies / release)
|
- Real ETH/token transactions. That’s the main reason we have separate .apk build for automation needs - it defaults to Sepolia network. Also it has enabled keycard test menu, ENS names and chat commands are also on Sepolia network (the same in PR builds, but not in nightlies / release)
|
||||||
- Autologin/Biometric related actions (autologin available when device meets certain conditions like the it has set unlock password and device is not rooted: all emulators are rooted in SauceLabs)
|
- Autologin/Biometric related actions (autologin available when device meets certain conditions like the it has set unlock password and device is not rooted: all emulators are rooted in SauceLabs)
|
||||||
|
|
||||||
## Brief flow for test to be automated
|
## Brief flow for test to be automated
|
||||||
|
|
|
@ -14,9 +14,8 @@ RCT_EXPORT_MODULE();
|
||||||
RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
||||||
jsLogs:(NSString *)jsLogs
|
jsLogs:(NSString *)jsLogs
|
||||||
callback:(RCTResponseSenderBlock)callback) {
|
callback:(RCTResponseSenderBlock)callback) {
|
||||||
// TODO: Implement SendLogs for iOS
|
|
||||||
#if DEBUG
|
#if DEBUG
|
||||||
NSLog(@"SendLogs() method called, not implemented");
|
NSLog(@"SendLogs() method called");
|
||||||
#endif
|
#endif
|
||||||
NSFileManager *fileManager = [NSFileManager defaultManager];
|
NSFileManager *fileManager = [NSFileManager defaultManager];
|
||||||
NSError *error = nil;
|
NSError *error = nil;
|
||||||
|
@ -34,25 +33,6 @@ RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
||||||
|
|
||||||
NSURL *dbFile = [logsFolderName URLByAppendingPathComponent:@"db.json"];
|
NSURL *dbFile = [logsFolderName URLByAppendingPathComponent:@"db.json"];
|
||||||
NSURL *jsLogsFile = [logsFolderName URLByAppendingPathComponent:@"Status.log"];
|
NSURL *jsLogsFile = [logsFolderName URLByAppendingPathComponent:@"Status.log"];
|
||||||
#if DEBUG
|
|
||||||
NSString *networkDirPath = @"ethereum/mainnet_rpc_dev";
|
|
||||||
#else
|
|
||||||
NSString *networkDirPath = @"ethereum/mainnet_rpc";
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if DEBUG
|
|
||||||
NSString *goerliNetworkDirPath = @"ethereum/goerli_rpc_dev";
|
|
||||||
#else
|
|
||||||
NSString *goerliNetworkDirPath = @"ethereum/goerli_rpc";
|
|
||||||
#endif
|
|
||||||
|
|
||||||
NSURL *networkDir = [rootUrl URLByAppendingPathComponent:networkDirPath];
|
|
||||||
NSURL *originalGethLogsFile = [networkDir URLByAppendingPathComponent:@"geth.log"];
|
|
||||||
NSURL *gethLogsFile = [logsFolderName URLByAppendingPathComponent:@"mainnet_geth.log"];
|
|
||||||
|
|
||||||
NSURL *goerliNetworkDir = [rootUrl URLByAppendingPathComponent:goerliNetworkDirPath];
|
|
||||||
NSURL *goerliGethLogsFile = [goerliNetworkDir URLByAppendingPathComponent:@"geth.log"];
|
|
||||||
NSURL *goerliLogsFile = [logsFolderName URLByAppendingPathComponent:@"goerli_geth.log"];
|
|
||||||
|
|
||||||
NSURL *mainGethLogsFile = [rootUrl URLByAppendingPathComponent:@"geth.log"];
|
NSURL *mainGethLogsFile = [rootUrl URLByAppendingPathComponent:@"geth.log"];
|
||||||
NSURL *mainLogsFile = [logsFolderName URLByAppendingPathComponent:@"geth.log"];
|
NSURL *mainLogsFile = [logsFolderName URLByAppendingPathComponent:@"geth.log"];
|
||||||
|
@ -62,10 +42,6 @@ RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
||||||
[dbJson writeToFile:dbFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
[dbJson writeToFile:dbFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
||||||
[jsLogs writeToFile:jsLogsFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
[jsLogs writeToFile:jsLogsFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
||||||
|
|
||||||
//NSString* gethLogs = StatusgoExportNodeLogs();
|
|
||||||
//[gethLogs writeToFile:gethLogsFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
|
||||||
[fileManager copyItemAtPath:originalGethLogsFile.path toPath:gethLogsFile.path error:nil];
|
|
||||||
[fileManager copyItemAtPath:goerliGethLogsFile.path toPath:goerliLogsFile.path error:nil];
|
|
||||||
[fileManager copyItemAtPath:mainGethLogsFile.path toPath:mainLogsFile.path error:nil];
|
[fileManager copyItemAtPath:mainGethLogsFile.path toPath:mainLogsFile.path error:nil];
|
||||||
|
|
||||||
if ([fileManager fileExistsAtPath:requestsLogFile.path]) {
|
if ([fileManager fileExistsAtPath:requestsLogFile.path]) {
|
||||||
|
|
|
@ -32,12 +32,9 @@ trap "rm -vf ${SECRETS_FILE_PATH}" EXIT ERR INT QUIT
|
||||||
# Names of variables containing secrets to save in env file.
|
# Names of variables containing secrets to save in env file.
|
||||||
SECRETS_ENV_VARS=(
|
SECRETS_ENV_VARS=(
|
||||||
'ALCHEMY_ETHEREUM_MAINNET_TOKEN'
|
'ALCHEMY_ETHEREUM_MAINNET_TOKEN'
|
||||||
'ALCHEMY_ETHEREUM_GOERLI_TOKEN'
|
|
||||||
'ALCHEMY_ETHEREUM_SEPOLIA_TOKEN'
|
'ALCHEMY_ETHEREUM_SEPOLIA_TOKEN'
|
||||||
'ALCHEMY_ARBITRUM_GOERLI_TOKEN'
|
|
||||||
'ALCHEMY_ARBITRUM_MAINNET_TOKEN'
|
'ALCHEMY_ARBITRUM_MAINNET_TOKEN'
|
||||||
'ALCHEMY_ARBITRUM_SEPOLIA_TOKEN'
|
'ALCHEMY_ARBITRUM_SEPOLIA_TOKEN'
|
||||||
'ALCHEMY_OPTIMISM_GOERLI_TOKEN'
|
|
||||||
'ALCHEMY_OPTIMISM_MAINNET_TOKEN'
|
'ALCHEMY_OPTIMISM_MAINNET_TOKEN'
|
||||||
'ALCHEMY_OPTIMISM_SEPOLIA_TOKEN'
|
'ALCHEMY_OPTIMISM_SEPOLIA_TOKEN'
|
||||||
'RARIBLE_MAINNET_API_KEY'
|
'RARIBLE_MAINNET_API_KEY'
|
||||||
|
|
|
@ -75,13 +75,10 @@
|
||||||
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
||||||
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
||||||
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||||
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||||
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
||||||
:compiler-options {:output-feature-set :es5
|
:compiler-options {:output-feature-set :es5
|
||||||
;; We disable `:fn-deprecated` warnings because we
|
;; We disable `:fn-deprecated` warnings because we
|
||||||
|
@ -114,13 +111,10 @@
|
||||||
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
||||||
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
||||||
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||||
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||||
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
||||||
:compiler-options {:output-feature-set :es6
|
:compiler-options {:output-feature-set :es6
|
||||||
;;disable for android build as there
|
;;disable for android build as there
|
||||||
|
@ -158,13 +152,10 @@
|
||||||
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
||||||
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
||||||
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||||
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||||
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||||
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
|
||||||
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"
|
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"
|
||||||
status-im.config/WALLET_CONNECT_PROJECT_ID #shadow/env "WALLET_CONNECT_PROJECT_ID"}
|
status-im.config/WALLET_CONNECT_PROJECT_ID #shadow/env "WALLET_CONNECT_PROJECT_ID"}
|
||||||
:compiler-options
|
:compiler-options
|
||||||
|
|
|
@ -20,9 +20,9 @@
|
||||||
{:mainnet {:name "Ether"
|
{:mainnet {:name "Ether"
|
||||||
:symbol :ETH
|
:symbol :ETH
|
||||||
:decimals 18}
|
:decimals 18}
|
||||||
:goerli {:name "Goerli Ether"
|
:sepolia {:name "Sepolia Ether"
|
||||||
:symbol :ETH
|
:symbol :ETH
|
||||||
:symbol-display :ETHgo
|
:symbol-display :ETH
|
||||||
:decimals 18}
|
:decimals 18}
|
||||||
:xdai {:name "xDAI"
|
:xdai {:name "xDAI"
|
||||||
:symbol :ETH
|
:symbol :ETH
|
||||||
|
|
|
@ -15,12 +15,12 @@
|
||||||
|
|
||||||
(def etherscan-supported?
|
(def etherscan-supported?
|
||||||
#{(chain/chain-keyword->chain-id :mainnet)
|
#{(chain/chain-keyword->chain-id :mainnet)
|
||||||
(chain/chain-keyword->chain-id :goerli)})
|
(chain/chain-keyword->chain-id :sepolia)})
|
||||||
|
|
||||||
(def binance-mainnet-chain-id (chain/chain-keyword->chain-id :bsc))
|
(def binance-mainnet-chain-id (chain/chain-keyword->chain-id :bsc))
|
||||||
(def binance-testnet-chain-id (chain/chain-keyword->chain-id :bsc-testnet))
|
(def binance-testnet-chain-id (chain/chain-keyword->chain-id :bsc-testnet))
|
||||||
|
|
||||||
(def network->subdomain {5 "goerli"})
|
(def network->subdomain {11155111 "sepolia"})
|
||||||
|
|
||||||
(defn get-transaction-details-url
|
(defn get-transaction-details-url
|
||||||
[chain-id tx-hash]
|
[chain-id tx-hash]
|
||||||
|
|
|
@ -18,28 +18,23 @@
|
||||||
(goog-define RARIBLE_MAINNET_API_KEY "")
|
(goog-define RARIBLE_MAINNET_API_KEY "")
|
||||||
(goog-define RARIBLE_TESTNET_API_KEY "")
|
(goog-define RARIBLE_TESTNET_API_KEY "")
|
||||||
(goog-define ALCHEMY_ETHEREUM_MAINNET_TOKEN "")
|
(goog-define ALCHEMY_ETHEREUM_MAINNET_TOKEN "")
|
||||||
(goog-define ALCHEMY_ETHEREUM_GOERLI_TOKEN "")
|
|
||||||
(goog-define ALCHEMY_ETHEREUM_SEPOLIA_TOKEN "")
|
(goog-define ALCHEMY_ETHEREUM_SEPOLIA_TOKEN "")
|
||||||
(goog-define ALCHEMY_ARBITRUM_MAINNET_TOKEN "")
|
(goog-define ALCHEMY_ARBITRUM_MAINNET_TOKEN "")
|
||||||
(goog-define ALCHEMY_ARBITRUM_GOERLI_TOKEN "")
|
|
||||||
(goog-define ALCHEMY_ARBITRUM_SEPOLIA_TOKEN "")
|
(goog-define ALCHEMY_ARBITRUM_SEPOLIA_TOKEN "")
|
||||||
(goog-define ALCHEMY_OPTIMISM_MAINNET_TOKEN "")
|
(goog-define ALCHEMY_OPTIMISM_MAINNET_TOKEN "")
|
||||||
(goog-define ALCHEMY_OPTIMISM_GOERLI_TOKEN "")
|
|
||||||
(goog-define ALCHEMY_OPTIMISM_SEPOLIA_TOKEN "")
|
(goog-define ALCHEMY_OPTIMISM_SEPOLIA_TOKEN "")
|
||||||
(goog-define WALLET_CONNECT_PROJECT_ID "87815d72a81d739d2a7ce15c2cfdefb3")
|
(goog-define WALLET_CONNECT_PROJECT_ID "87815d72a81d739d2a7ce15c2cfdefb3")
|
||||||
(goog-define MIXPANEL_APP_ID "3350627")
|
(goog-define MIXPANEL_APP_ID "3350627")
|
||||||
(goog-define MIXPANEL_TOKEN "5c73bda2d36a9f688a5ee45641fb6775")
|
(goog-define MIXPANEL_TOKEN "5c73bda2d36a9f688a5ee45641fb6775")
|
||||||
|
|
||||||
(def mainnet-rpc-url (str "https://eth-archival.rpc.grove.city/v1/" POKT_TOKEN))
|
(def mainnet-rpc-url (str "https://eth-archival.rpc.grove.city/v1/" POKT_TOKEN))
|
||||||
(def goerli-rpc-url (str "https://goerli-archival.gateway.pokt.network/v1/lb/" POKT_TOKEN))
|
(def sepolia-rpc-url (str "https://sepolia-archival.rpc.grove.city/v1/" POKT_TOKEN))
|
||||||
(def mainnet-chain-explorer-link "https://etherscan.io/address/")
|
(def mainnet-chain-explorer-link "https://etherscan.io/address/")
|
||||||
(def optimism-mainnet-chain-explorer-link "https://optimistic.etherscan.io/address/")
|
(def optimism-mainnet-chain-explorer-link "https://optimistic.etherscan.io/address/")
|
||||||
(def arbitrum-mainnet-chain-explorer-link "https://arbiscan.io/address/")
|
(def arbitrum-mainnet-chain-explorer-link "https://arbiscan.io/address/")
|
||||||
(def sepolia-chain-explorer-link "https://sepolia.etherscan.io/address/")
|
(def sepolia-chain-explorer-link "https://sepolia.etherscan.io/address/")
|
||||||
(def optimism-sepolia-chain-explorer-link "https://sepolia-optimistic.etherscan.io/address/")
|
(def optimism-sepolia-chain-explorer-link "https://sepolia-optimistic.etherscan.io/address/")
|
||||||
(def arbitrum-sepolia-chain-explorer-link "https://sepolia.arbiscan.io/address/")
|
(def arbitrum-sepolia-chain-explorer-link "https://sepolia.arbiscan.io/address/")
|
||||||
(def goerli-chain-explorer-link "https://goerli.etherscan.io/address/")
|
|
||||||
(def optimism-goerli-chain-explorer-link "https://goerli-optimistic.etherscan.io/address/")
|
|
||||||
(def opensea-link "https://opensea.io")
|
(def opensea-link "https://opensea.io")
|
||||||
(def opensea-tesnet-link "https://testnets.opensea.io")
|
(def opensea-tesnet-link "https://testnets.opensea.io")
|
||||||
|
|
||||||
|
@ -79,7 +74,6 @@
|
||||||
(def log-request-go (enabled? (get-config :LOG_REQUEST_GO "0")))
|
(def log-request-go (enabled? (get-config :LOG_REQUEST_GO "0")))
|
||||||
(def fleet (get-config :FLEET ""))
|
(def fleet (get-config :FLEET ""))
|
||||||
(def apn-topic (get-config :APN_TOPIC "im.status.ethereum"))
|
(def apn-topic (get-config :APN_TOPIC "im.status.ethereum"))
|
||||||
(def default-network (get-config :DEFAULT_NETWORK "goerli_rpc"))
|
|
||||||
(def max-installations 2)
|
(def max-installations 2)
|
||||||
; currently not supported in status-go
|
; currently not supported in status-go
|
||||||
(def enable-remove-profile-picture? false)
|
(def enable-remove-profile-picture? false)
|
||||||
|
@ -100,13 +94,13 @@
|
||||||
(def verify-transaction-url
|
(def verify-transaction-url
|
||||||
(if (= :mainnet (chain/chain-id->chain-keyword verify-transaction-chain-id))
|
(if (= :mainnet (chain/chain-id->chain-keyword verify-transaction-chain-id))
|
||||||
mainnet-rpc-url
|
mainnet-rpc-url
|
||||||
goerli-rpc-url))
|
sepolia-rpc-url))
|
||||||
|
|
||||||
(def verify-ens-chain-id (js/parseInt (get-config :VERIFY_ENS_CHAIN_ID "1")))
|
(def verify-ens-chain-id (js/parseInt (get-config :VERIFY_ENS_CHAIN_ID "1")))
|
||||||
(def verify-ens-url
|
(def verify-ens-url
|
||||||
(if (= :mainnet (chain/chain-id->chain-keyword verify-ens-chain-id))
|
(if (= :mainnet (chain/chain-id->chain-keyword verify-ens-chain-id))
|
||||||
mainnet-rpc-url
|
mainnet-rpc-url
|
||||||
goerli-rpc-url))
|
sepolia-rpc-url))
|
||||||
(def verify-ens-contract-address
|
(def verify-ens-contract-address
|
||||||
(get-config :VERIFY_ENS_CONTRACT_ADDRESS
|
(get-config :VERIFY_ENS_CONTRACT_ADDRESS
|
||||||
((chain/chain-id->chain-keyword verify-ens-chain-id) utils.ens/ens-registries)))
|
((chain/chain-id->chain-keyword verify-ens-chain-id) utils.ens/ens-registries)))
|
||||||
|
|
|
@ -473,30 +473,22 @@
|
||||||
|
|
||||||
;; wallet
|
;; wallet
|
||||||
(def ^:const ethereum-mainnet-chain-id 1)
|
(def ^:const ethereum-mainnet-chain-id 1)
|
||||||
(def ^:const ethereum-goerli-chain-id 5)
|
|
||||||
(def ^:const ethereum-sepolia-chain-id 11155111)
|
(def ^:const ethereum-sepolia-chain-id 11155111)
|
||||||
(def ^:const arbitrum-mainnet-chain-id 42161)
|
(def ^:const arbitrum-mainnet-chain-id 42161)
|
||||||
(def ^:const arbitrum-goerli-chain-id 421613)
|
|
||||||
(def ^:const arbitrum-sepolia-chain-id 421614)
|
(def ^:const arbitrum-sepolia-chain-id 421614)
|
||||||
(def ^:const optimism-mainnet-chain-id 10)
|
(def ^:const optimism-mainnet-chain-id 10)
|
||||||
(def ^:const optimism-goerli-chain-id 420)
|
|
||||||
(def ^:const optimism-sepolia-chain-id 11155420)
|
(def ^:const optimism-sepolia-chain-id 11155420)
|
||||||
|
|
||||||
(def opensea-url-names
|
(def opensea-url-names
|
||||||
{:ethereum "ethereum"
|
{:ethereum "ethereum"
|
||||||
:sepolia "sepolia"
|
:sepolia "sepolia"})
|
||||||
:goerli "goerli"})
|
|
||||||
|
|
||||||
(def ^:const ethereum "ethereum")
|
(def ^:const ethereum "ethereum")
|
||||||
(def ^:const sepolia "sepolia")
|
(def ^:const sepolia "sepolia")
|
||||||
(def ^:const goerli "goerli")
|
|
||||||
|
|
||||||
(def ^:const mainnet-chain-ids
|
(def ^:const mainnet-chain-ids
|
||||||
#{ethereum-mainnet-chain-id arbitrum-mainnet-chain-id optimism-mainnet-chain-id})
|
#{ethereum-mainnet-chain-id arbitrum-mainnet-chain-id optimism-mainnet-chain-id})
|
||||||
|
|
||||||
(def ^:const goerli-chain-ids
|
|
||||||
#{ethereum-goerli-chain-id arbitrum-goerli-chain-id optimism-goerli-chain-id})
|
|
||||||
|
|
||||||
(def ^:const sepolia-chain-ids
|
(def ^:const sepolia-chain-ids
|
||||||
#{ethereum-sepolia-chain-id arbitrum-sepolia-chain-id optimism-sepolia-chain-id})
|
#{ethereum-sepolia-chain-id arbitrum-sepolia-chain-id optimism-sepolia-chain-id})
|
||||||
|
|
||||||
|
@ -516,7 +508,6 @@
|
||||||
(def ^:const arbitrum-full-name "Arbitrum")
|
(def ^:const arbitrum-full-name "Arbitrum")
|
||||||
|
|
||||||
(def ^:const sepolia-full-name "Sepolia")
|
(def ^:const sepolia-full-name "Sepolia")
|
||||||
(def ^:const goerli-full-name "Goerli")
|
|
||||||
|
|
||||||
(def ^:const mainnet-network-name :mainnet)
|
(def ^:const mainnet-network-name :mainnet)
|
||||||
(def ^:const ethereum-network-name :ethereum)
|
(def ^:const ethereum-network-name :ethereum)
|
||||||
|
|
|
@ -22,13 +22,10 @@
|
||||||
:raribleMainnetAPIKey config/RARIBLE_MAINNET_API_KEY
|
:raribleMainnetAPIKey config/RARIBLE_MAINNET_API_KEY
|
||||||
:raribleTestnetAPIKey config/RARIBLE_TESTNET_API_KEY
|
:raribleTestnetAPIKey config/RARIBLE_TESTNET_API_KEY
|
||||||
:alchemyEthereumMainnetToken config/ALCHEMY_ETHEREUM_MAINNET_TOKEN
|
:alchemyEthereumMainnetToken config/ALCHEMY_ETHEREUM_MAINNET_TOKEN
|
||||||
:alchemyEthereumGoerliToken config/ALCHEMY_ETHEREUM_GOERLI_TOKEN
|
|
||||||
:alchemyEthereumSepoliaToken config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN
|
:alchemyEthereumSepoliaToken config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN
|
||||||
:alchemyOptimismMainnetToken config/ALCHEMY_OPTIMISM_MAINNET_TOKEN
|
:alchemyOptimismMainnetToken config/ALCHEMY_OPTIMISM_MAINNET_TOKEN
|
||||||
:alchemyOptimismGoerliToken config/ALCHEMY_OPTIMISM_GOERLI_TOKEN
|
|
||||||
:alchemyOptimismSepoliaToken config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN
|
:alchemyOptimismSepoliaToken config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN
|
||||||
:alchemyArbitrumMainnetToken config/ALCHEMY_ARBITRUM_MAINNET_TOKEN
|
:alchemyArbitrumMainnetToken config/ALCHEMY_ARBITRUM_MAINNET_TOKEN
|
||||||
:alchemyArbitrumGoerliToken config/ALCHEMY_ARBITRUM_GOERLI_TOKEN
|
|
||||||
:alchemyArbitrumSepoliaToken config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN})
|
:alchemyArbitrumSepoliaToken config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN})
|
||||||
|
|
||||||
(defn create
|
(defn create
|
||||||
|
|
|
@ -50,17 +50,6 @@
|
||||||
{:on-success on-success}])
|
{:on-success on-success}])
|
||||||
:on-cancel nil}]]})))
|
:on-cancel nil}]]})))
|
||||||
|
|
||||||
(rf/reg-event-fx :profile.settings/toggle-goerli-test-network
|
|
||||||
(fn [{:keys [db]}]
|
|
||||||
(let [value (get-in db [:profile/profile :is-goerli-enabled?])
|
|
||||||
on-success #(rf/dispatch [:logout])]
|
|
||||||
{:fx [[:ui/show-confirmation
|
|
||||||
{:content (i18n/label :t/goerli-testnet-toggle-confirmation)
|
|
||||||
:on-accept #(rf/dispatch [:profile.settings/profile-update :is-goerli-enabled?
|
|
||||||
(not value)
|
|
||||||
{:on-success on-success}])
|
|
||||||
:on-cancel nil}]]})))
|
|
||||||
|
|
||||||
(rf/reg-event-fx :profile.settings/change-preview-privacy
|
(rf/reg-event-fx :profile.settings/change-preview-privacy
|
||||||
(fn [_ [private?]]
|
(fn [_ [private?]]
|
||||||
(let [private?' (boolean private?)]
|
(let [private?' (boolean private?)]
|
||||||
|
|
|
@ -357,8 +357,7 @@
|
||||||
{:chain-id chain-id
|
{:chain-id chain-id
|
||||||
:token-id token-id
|
:token-id token-id
|
||||||
:contract-address contract-address
|
:contract-address contract-address
|
||||||
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])})]
|
||||||
:is-goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])})]
|
|
||||||
{:fx [[:dispatch
|
{:fx [[:dispatch
|
||||||
[:hide-bottom-sheet]]
|
[:hide-bottom-sheet]]
|
||||||
[:dispatch-later
|
[:dispatch-later
|
||||||
|
@ -377,5 +376,4 @@
|
||||||
{:chain-id chain-id
|
{:chain-id chain-id
|
||||||
:token-id token-id
|
:token-id token-id
|
||||||
:contract-address contract-address
|
:contract-address contract-address
|
||||||
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])})]]]}))
|
||||||
:is-goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])})]]]}))
|
|
||||||
|
|
|
@ -33,17 +33,11 @@
|
||||||
(when (> total 1) (str "x" total)))
|
(when (> total 1) (str "x" total)))
|
||||||
|
|
||||||
(defn- get-opensea-network-name
|
(defn- get-opensea-network-name
|
||||||
[chain-id test-networks-enabled? is-goerli-enabled?]
|
[chain-id test-networks-enabled?]
|
||||||
(let [network-kw (network-utils/id->network chain-id)
|
(let [network-kw (network-utils/id->network chain-id)
|
||||||
network-name (name network-kw)
|
network-name (name network-kw)
|
||||||
mainnet? (= :mainnet network-kw)]
|
mainnet? (= :mainnet network-kw)]
|
||||||
(cond (and test-networks-enabled? is-goerli-enabled? mainnet?)
|
(cond (and test-networks-enabled? mainnet?)
|
||||||
(:goerli constants/opensea-url-names)
|
|
||||||
|
|
||||||
(and test-networks-enabled? is-goerli-enabled?)
|
|
||||||
(str network-name "-" (:goerli constants/opensea-url-names))
|
|
||||||
|
|
||||||
(and test-networks-enabled? mainnet?)
|
|
||||||
(:sepolia constants/opensea-url-names)
|
(:sepolia constants/opensea-url-names)
|
||||||
|
|
||||||
test-networks-enabled?
|
test-networks-enabled?
|
||||||
|
@ -63,11 +57,10 @@
|
||||||
|
|
||||||
(defn get-opensea-collectible-url
|
(defn get-opensea-collectible-url
|
||||||
[{:keys [chain-id token-id contract-address
|
[{:keys [chain-id token-id contract-address
|
||||||
test-networks-enabled? is-goerli-enabled?]}]
|
test-networks-enabled?]}]
|
||||||
(let [base-link (get-opensea-base-url test-networks-enabled?)
|
(let [base-link (get-opensea-base-url test-networks-enabled?)
|
||||||
opensea-network-name (get-opensea-network-name chain-id
|
opensea-network-name (get-opensea-network-name chain-id
|
||||||
test-networks-enabled?
|
test-networks-enabled?)]
|
||||||
is-goerli-enabled?)]
|
|
||||||
(str base-link "/assets/" opensea-network-name "/" contract-address "/" token-id)))
|
(str base-link "/assets/" opensea-network-name "/" contract-address "/" token-id)))
|
||||||
|
|
||||||
(defn get-collectible-unique-id
|
(defn get-collectible-unique-id
|
||||||
|
|
|
@ -43,26 +43,4 @@
|
||||||
:contract-address contract-address
|
:contract-address contract-address
|
||||||
:token-id token-id
|
:token-id token-id
|
||||||
:test-networks-enabled? true})
|
:test-networks-enabled? true})
|
||||||
"https://testnets.opensea.io/assets/optimism-sepolia/0xC/0xT")))
|
"https://testnets.opensea.io/assets/optimism-sepolia/0xC/0xT"))))
|
||||||
(testing "get-opensea-collectible-url goerli"
|
|
||||||
(is (= (utils/get-opensea-collectible-url {:chain-id constants/ethereum-goerli-chain-id
|
|
||||||
:contract-address contract-address
|
|
||||||
:token-id token-id
|
|
||||||
:test-networks-enabled? true
|
|
||||||
:is-goerli-enabled? true})
|
|
||||||
"https://testnets.opensea.io/assets/goerli/0xC/0xT")))
|
|
||||||
(testing "get-opensea-collectible-url goerli arbitrum"
|
|
||||||
(is (= (utils/get-opensea-collectible-url {:chain-id constants/arbitrum-goerli-chain-id
|
|
||||||
:contract-address contract-address
|
|
||||||
:token-id token-id
|
|
||||||
:test-networks-enabled? true
|
|
||||||
:is-goerli-enabled? true})
|
|
||||||
"https://testnets.opensea.io/assets/arbitrum-goerli/0xC/0xT")))
|
|
||||||
|
|
||||||
(testing "get-opensea-collectible-url goerli optimism"
|
|
||||||
(is (= (utils/get-opensea-collectible-url {:chain-id constants/optimism-goerli-chain-id
|
|
||||||
:contract-address contract-address
|
|
||||||
:token-id token-id
|
|
||||||
:test-networks-enabled? true
|
|
||||||
:is-goerli-enabled? true})
|
|
||||||
"https://testnets.opensea.io/assets/optimism-goerli/0xC/0xT"))))
|
|
||||||
|
|
|
@ -14,12 +14,6 @@
|
||||||
(= chain-id constants/optimism-mainnet-chain-id)
|
(= chain-id constants/optimism-mainnet-chain-id)
|
||||||
config/optimism-mainnet-chain-explorer-link
|
config/optimism-mainnet-chain-explorer-link
|
||||||
|
|
||||||
(= chain-id constants/ethereum-goerli-chain-id)
|
|
||||||
config/goerli-chain-explorer-link
|
|
||||||
|
|
||||||
(= chain-id constants/optimism-goerli-chain-id)
|
|
||||||
config/optimism-goerli-chain-explorer-link
|
|
||||||
|
|
||||||
(= chain-id constants/ethereum-sepolia-chain-id)
|
(= chain-id constants/ethereum-sepolia-chain-id)
|
||||||
config/sepolia-chain-explorer-link
|
config/sepolia-chain-explorer-link
|
||||||
|
|
||||||
|
|
|
@ -10,58 +10,42 @@
|
||||||
|
|
||||||
(def id->network
|
(def id->network
|
||||||
{constants/ethereum-mainnet-chain-id constants/mainnet-network-name
|
{constants/ethereum-mainnet-chain-id constants/mainnet-network-name
|
||||||
constants/ethereum-goerli-chain-id constants/mainnet-network-name
|
|
||||||
constants/ethereum-sepolia-chain-id constants/mainnet-network-name
|
constants/ethereum-sepolia-chain-id constants/mainnet-network-name
|
||||||
constants/optimism-mainnet-chain-id constants/optimism-network-name
|
constants/optimism-mainnet-chain-id constants/optimism-network-name
|
||||||
constants/optimism-goerli-chain-id constants/optimism-network-name
|
|
||||||
constants/optimism-sepolia-chain-id constants/optimism-network-name
|
constants/optimism-sepolia-chain-id constants/optimism-network-name
|
||||||
constants/arbitrum-mainnet-chain-id constants/arbitrum-network-name
|
constants/arbitrum-mainnet-chain-id constants/arbitrum-network-name
|
||||||
constants/arbitrum-goerli-chain-id constants/arbitrum-network-name
|
|
||||||
constants/arbitrum-sepolia-chain-id constants/arbitrum-network-name})
|
constants/arbitrum-sepolia-chain-id constants/arbitrum-network-name})
|
||||||
|
|
||||||
(defn- get-chain-id
|
(defn- get-chain-id
|
||||||
[{:keys [mainnet-chain-id sepolia-chain-id goerli-chain-id testnet-enabled? goerli-enabled?]}]
|
[{:keys [mainnet-chain-id sepolia-chain-id testnet-enabled?]}]
|
||||||
(cond
|
(if testnet-enabled?
|
||||||
(and testnet-enabled? goerli-enabled?)
|
|
||||||
goerli-chain-id
|
|
||||||
|
|
||||||
testnet-enabled?
|
|
||||||
sepolia-chain-id
|
sepolia-chain-id
|
||||||
|
|
||||||
:else
|
|
||||||
mainnet-chain-id))
|
mainnet-chain-id))
|
||||||
|
|
||||||
(defn network->chain-id
|
(defn network->chain-id
|
||||||
([db network]
|
([db network]
|
||||||
(let [{:keys [test-networks-enabled? is-goerli-enabled?]} (:profile/profile db)]
|
(let [{:keys [test-networks-enabled?]} (:profile/profile db)]
|
||||||
(network->chain-id {:network network
|
(network->chain-id {:network network
|
||||||
:testnet-enabled? test-networks-enabled?
|
:testnet-enabled? test-networks-enabled?})))
|
||||||
:goerli-enabled? is-goerli-enabled?})))
|
([{:keys [network testnet-enabled?]}]
|
||||||
([{:keys [network testnet-enabled? goerli-enabled?]}]
|
|
||||||
(condp contains? (keyword network)
|
(condp contains? (keyword network)
|
||||||
#{constants/mainnet-network-name (keyword constants/mainnet-short-name)}
|
#{constants/mainnet-network-name (keyword constants/mainnet-short-name)}
|
||||||
(get-chain-id
|
(get-chain-id
|
||||||
{:mainnet-chain-id constants/ethereum-mainnet-chain-id
|
{:mainnet-chain-id constants/ethereum-mainnet-chain-id
|
||||||
:sepolia-chain-id constants/ethereum-sepolia-chain-id
|
:sepolia-chain-id constants/ethereum-sepolia-chain-id
|
||||||
:goerli-chain-id constants/ethereum-goerli-chain-id
|
:testnet-enabled? testnet-enabled?})
|
||||||
:testnet-enabled? testnet-enabled?
|
|
||||||
:goerli-enabled? goerli-enabled?})
|
|
||||||
|
|
||||||
#{constants/optimism-network-name (keyword constants/optimism-short-name)}
|
#{constants/optimism-network-name (keyword constants/optimism-short-name)}
|
||||||
(get-chain-id
|
(get-chain-id
|
||||||
{:mainnet-chain-id constants/optimism-mainnet-chain-id
|
{:mainnet-chain-id constants/optimism-mainnet-chain-id
|
||||||
:sepolia-chain-id constants/optimism-sepolia-chain-id
|
:sepolia-chain-id constants/optimism-sepolia-chain-id
|
||||||
:goerli-chain-id constants/optimism-goerli-chain-id
|
:testnet-enabled? testnet-enabled?})
|
||||||
:testnet-enabled? testnet-enabled?
|
|
||||||
:goerli-enabled? goerli-enabled?})
|
|
||||||
|
|
||||||
#{constants/arbitrum-network-name (keyword constants/arbitrum-short-name)}
|
#{constants/arbitrum-network-name (keyword constants/arbitrum-short-name)}
|
||||||
(get-chain-id
|
(get-chain-id
|
||||||
{:mainnet-chain-id constants/arbitrum-mainnet-chain-id
|
{:mainnet-chain-id constants/arbitrum-mainnet-chain-id
|
||||||
:sepolia-chain-id constants/arbitrum-sepolia-chain-id
|
:sepolia-chain-id constants/arbitrum-sepolia-chain-id
|
||||||
:goerli-chain-id constants/arbitrum-goerli-chain-id
|
:testnet-enabled? testnet-enabled?}))))
|
||||||
:testnet-enabled? testnet-enabled?
|
|
||||||
:goerli-enabled? goerli-enabled?}))))
|
|
||||||
|
|
||||||
(defn network-list
|
(defn network-list
|
||||||
[{:keys [balances-per-chain]} networks]
|
[{:keys [balances-per-chain]} networks]
|
||||||
|
@ -82,19 +66,13 @@
|
||||||
(network-list $ networks)))
|
(network-list $ networks)))
|
||||||
|
|
||||||
(defn get-default-chain-ids-by-mode
|
(defn get-default-chain-ids-by-mode
|
||||||
[{:keys [test-networks-enabled? is-goerli-enabled?]}]
|
[{:keys [test-networks-enabled?]}]
|
||||||
(cond
|
(if test-networks-enabled?
|
||||||
(and test-networks-enabled? is-goerli-enabled?)
|
|
||||||
constants/goerli-chain-ids
|
|
||||||
|
|
||||||
test-networks-enabled?
|
|
||||||
constants/sepolia-chain-ids
|
constants/sepolia-chain-ids
|
||||||
|
|
||||||
:else
|
|
||||||
constants/mainnet-chain-ids))
|
constants/mainnet-chain-ids))
|
||||||
|
|
||||||
(defn resolve-receiver-networks
|
(defn resolve-receiver-networks
|
||||||
[{:keys [prefix testnet-enabled? goerli-enabled?]}]
|
[{:keys [prefix testnet-enabled?]}]
|
||||||
(let [prefix (if (string/blank? prefix)
|
(let [prefix (if (string/blank? prefix)
|
||||||
constants/default-multichain-address-prefix
|
constants/default-multichain-address-prefix
|
||||||
prefix)
|
prefix)
|
||||||
|
@ -104,8 +82,7 @@
|
||||||
(mapv
|
(mapv
|
||||||
#(network->chain-id
|
#(network->chain-id
|
||||||
{:network %
|
{:network %
|
||||||
:testnet-enabled? testnet-enabled?
|
:testnet-enabled? testnet-enabled?})))))
|
||||||
:goerli-enabled? goerli-enabled?})))))
|
|
||||||
|
|
||||||
(def network->short-name
|
(def network->short-name
|
||||||
{constants/mainnet-network-name constants/mainnet-short-name
|
{constants/mainnet-network-name constants/mainnet-short-name
|
||||||
|
@ -185,16 +162,13 @@
|
||||||
[chain-id]
|
[chain-id]
|
||||||
(as-> chain-id $
|
(as-> chain-id $
|
||||||
(condp contains? $
|
(condp contains? $
|
||||||
#{constants/ethereum-mainnet-chain-id constants/ethereum-goerli-chain-id
|
#{constants/ethereum-mainnet-chain-id constants/ethereum-sepolia-chain-id}
|
||||||
constants/ethereum-sepolia-chain-id}
|
|
||||||
mainnet-network-details
|
mainnet-network-details
|
||||||
|
|
||||||
#{constants/arbitrum-mainnet-chain-id constants/arbitrum-goerli-chain-id
|
#{constants/arbitrum-mainnet-chain-id constants/arbitrum-sepolia-chain-id}
|
||||||
constants/arbitrum-sepolia-chain-id}
|
|
||||||
arbitrum-network-details
|
arbitrum-network-details
|
||||||
|
|
||||||
#{constants/optimism-mainnet-chain-id constants/optimism-goerli-chain-id
|
#{constants/optimism-mainnet-chain-id constants/optimism-sepolia-chain-id}
|
||||||
constants/optimism-sepolia-chain-id}
|
|
||||||
optimism-network-details
|
optimism-network-details
|
||||||
|
|
||||||
nil)
|
nil)
|
||||||
|
|
|
@ -6,19 +6,17 @@
|
||||||
|
|
||||||
(deftest network->chain-id-test
|
(deftest network->chain-id-test
|
||||||
(testing "network->chain-id function"
|
(testing "network->chain-id function"
|
||||||
(is (= (utils/network->chain-id {:network :mainnet :testnet-enabled? false :goerli-enabled? false})
|
(is (= (utils/network->chain-id {:network :mainnet :testnet-enabled? false})
|
||||||
constants/ethereum-mainnet-chain-id))
|
constants/ethereum-mainnet-chain-id))
|
||||||
(is (= (utils/network->chain-id {:network :eth :testnet-enabled? true :goerli-enabled? false})
|
(is (= (utils/network->chain-id {:network :eth :testnet-enabled? true})
|
||||||
constants/ethereum-sepolia-chain-id))
|
constants/ethereum-sepolia-chain-id))
|
||||||
(is (= (utils/network->chain-id {:network "optimism" :testnet-enabled? true :goerli-enabled? false})
|
(is (= (utils/network->chain-id {:network "optimism" :testnet-enabled? true})
|
||||||
constants/optimism-sepolia-chain-id))
|
constants/optimism-sepolia-chain-id))
|
||||||
(is (= (utils/network->chain-id {:network "oeth" :testnet-enabled? false :goerli-enabled? true})
|
(is (= (utils/network->chain-id {:network "oeth" :testnet-enabled? false})
|
||||||
constants/optimism-mainnet-chain-id))
|
constants/optimism-mainnet-chain-id))
|
||||||
(is (= (utils/network->chain-id {:network :oeth :testnet-enabled? true :goerli-enabled? true})
|
(is (= (utils/network->chain-id {:network :arb1 :testnet-enabled? false})
|
||||||
constants/optimism-goerli-chain-id))
|
|
||||||
(is (= (utils/network->chain-id {:network :arb1 :testnet-enabled? false :goerli-enabled? false})
|
|
||||||
constants/arbitrum-mainnet-chain-id))
|
constants/arbitrum-mainnet-chain-id))
|
||||||
(is (= (utils/network->chain-id {:network :arbitrum :testnet-enabled? true :goerli-enabled? false})
|
(is (= (utils/network->chain-id {:network :arbitrum :testnet-enabled? true})
|
||||||
constants/arbitrum-sepolia-chain-id))))
|
constants/arbitrum-sepolia-chain-id))))
|
||||||
|
|
||||||
(deftest short-names->network-preference-prefix-test
|
(deftest short-names->network-preference-prefix-test
|
||||||
|
|
|
@ -502,10 +502,8 @@
|
||||||
(for [[k v] chains :when (= v "down")] k))
|
(for [[k v] chains :when (= v "down")] k))
|
||||||
keys)
|
keys)
|
||||||
test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
||||||
is-goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])
|
|
||||||
chain-ids-by-mode (network-utils/get-default-chain-ids-by-mode
|
chain-ids-by-mode (network-utils/get-default-chain-ids-by-mode
|
||||||
{:test-networks-enabled? test-networks-enabled?
|
{:test-networks-enabled? test-networks-enabled?})
|
||||||
:is-goerli-enabled? is-goerli-enabled?})
|
|
||||||
chains-filtered-by-mode (remove #(not (contains? chain-ids-by-mode %)) down-chain-ids)
|
chains-filtered-by-mode (remove #(not (contains? chain-ids-by-mode %)) down-chain-ids)
|
||||||
chains-down? (and (network.data-store/online? db) (seq chains-filtered-by-mode))
|
chains-down? (and (network.data-store/online? db) (seq chains-filtered-by-mode))
|
||||||
chain-names (when chains-down?
|
chain-names (when chains-down?
|
||||||
|
@ -518,8 +516,7 @@
|
||||||
(when (seq down-chain-ids)
|
(when (seq down-chain-ids)
|
||||||
(log/info "[wallet] Chain(s) down: " down-chain-ids)
|
(log/info "[wallet] Chain(s) down: " down-chain-ids)
|
||||||
(log/info "[wallet] Chain name(s) down: " chain-names)
|
(log/info "[wallet] Chain name(s) down: " chain-names)
|
||||||
(log/info "[wallet] Test network enabled: " (boolean test-networks-enabled?))
|
(log/info "[wallet] Test network enabled: " (boolean test-networks-enabled?)))
|
||||||
(log/info "[wallet] Goerli network enabled: " (boolean is-goerli-enabled?)))
|
|
||||||
|
|
||||||
;; NOTE <shivekkhurana>: We used to show an error toast, but disabled it because the down
|
;; NOTE <shivekkhurana>: We used to show an error toast, but disabled it because the down
|
||||||
;; signal is sent randomly. Needs to be investigated and enabled again !
|
;; signal is sent randomly. Needs to be investigated and enabled again !
|
||||||
|
|
|
@ -152,11 +152,9 @@
|
||||||
(fn [{:keys [db]} [{:keys [address recipient stack-id start-flow?]}]]
|
(fn [{:keys [db]} [{:keys [address recipient stack-id start-flow?]}]]
|
||||||
(let [[prefix to-address] (utils/split-prefix-and-address address)
|
(let [[prefix to-address] (utils/split-prefix-and-address address)
|
||||||
testnet-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
testnet-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
||||||
goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])
|
|
||||||
receiver-networks (network-utils/resolve-receiver-networks
|
receiver-networks (network-utils/resolve-receiver-networks
|
||||||
{:prefix prefix
|
{:prefix prefix
|
||||||
:testnet-enabled? testnet-enabled?
|
:testnet-enabled? testnet-enabled?})
|
||||||
:goerli-enabled? goerli-enabled?})
|
|
||||||
collectible-tx? (send-utils/tx-type-collectible?
|
collectible-tx? (send-utils/tx-type-collectible?
|
||||||
(-> db :wallet :ui :send :tx-type))
|
(-> db :wallet :ui :send :tx-type))
|
||||||
collectible (when collectible-tx?
|
collectible (when collectible-tx?
|
||||||
|
|
|
@ -357,11 +357,9 @@
|
||||||
(testing "testing when collectible balance is more than 1"
|
(testing "testing when collectible balance is more than 1"
|
||||||
(let [collectible (collectible-with-balance 2)
|
(let [collectible (collectible-with-balance 2)
|
||||||
testnet-enabled? false
|
testnet-enabled? false
|
||||||
goerli-enabled? false
|
|
||||||
receiver-networks (network-utils/resolve-receiver-networks
|
receiver-networks (network-utils/resolve-receiver-networks
|
||||||
{:prefix prefix
|
{:prefix prefix
|
||||||
:testnet-enabled? testnet-enabled?
|
:testnet-enabled? testnet-enabled?})
|
||||||
:goerli-enabled? goerli-enabled?})
|
|
||||||
expected-result {:db {:wallet {:ui {:send {:other-props :value
|
expected-result {:db {:wallet {:ui {:send {:other-props :value
|
||||||
:recipient recipient
|
:recipient recipient
|
||||||
:to-address to-address
|
:to-address to-address
|
||||||
|
@ -371,8 +369,7 @@
|
||||||
:receiver-networks receiver-networks
|
:receiver-networks receiver-networks
|
||||||
:tx-type tx-type
|
:tx-type tx-type
|
||||||
:collectible collectible}}}
|
:collectible collectible}}}
|
||||||
:profile/profile {:test-networks-enabled? false
|
:profile/profile {:test-networks-enabled? false}}
|
||||||
:is-goerli-enabled? false}}
|
|
||||||
:fx [nil
|
:fx [nil
|
||||||
[:dispatch
|
[:dispatch
|
||||||
[:wallet/wizard-navigate-forward
|
[:wallet/wizard-navigate-forward
|
||||||
|
@ -383,8 +380,7 @@
|
||||||
{:wallet {:ui {:send {:other-props :value
|
{:wallet {:ui {:send {:other-props :value
|
||||||
:tx-type tx-type
|
:tx-type tx-type
|
||||||
:collectible collectible}}}
|
:collectible collectible}}}
|
||||||
:profile/profile {:test-networks-enabled? testnet-enabled?
|
:profile/profile {:test-networks-enabled? testnet-enabled?}})
|
||||||
:is-goerli-enabled? goerli-enabled?}})
|
|
||||||
(is (match? expected-result
|
(is (match? expected-result
|
||||||
(dispatch [event-id
|
(dispatch [event-id
|
||||||
{:address address
|
{:address address
|
||||||
|
@ -394,11 +390,9 @@
|
||||||
(testing "testing when collectible balance is 1"
|
(testing "testing when collectible balance is 1"
|
||||||
(let [collectible (collectible-with-balance 1)
|
(let [collectible (collectible-with-balance 1)
|
||||||
testnet-enabled? false
|
testnet-enabled? false
|
||||||
goerli-enabled? false
|
|
||||||
receiver-networks (network-utils/resolve-receiver-networks
|
receiver-networks (network-utils/resolve-receiver-networks
|
||||||
{:prefix prefix
|
{:prefix prefix
|
||||||
:testnet-enabled? testnet-enabled?
|
:testnet-enabled? testnet-enabled?})
|
||||||
:goerli-enabled? goerli-enabled?})
|
|
||||||
expected-result {:db {:wallet {:ui {:send {:other-props :value
|
expected-result {:db {:wallet {:ui {:send {:other-props :value
|
||||||
:recipient recipient
|
:recipient recipient
|
||||||
:to-address to-address
|
:to-address to-address
|
||||||
|
@ -408,8 +402,7 @@
|
||||||
:receiver-networks receiver-networks
|
:receiver-networks receiver-networks
|
||||||
:tx-type tx-type
|
:tx-type tx-type
|
||||||
:collectible collectible}}}
|
:collectible collectible}}}
|
||||||
:profile/profile {:test-networks-enabled? false
|
:profile/profile {:test-networks-enabled? false}}
|
||||||
:is-goerli-enabled? false}}
|
|
||||||
:fx [[:dispatch [:wallet/start-get-suggested-routes {:amount 1}]]
|
:fx [[:dispatch [:wallet/start-get-suggested-routes {:amount 1}]]
|
||||||
[:dispatch
|
[:dispatch
|
||||||
[:wallet/wizard-navigate-forward
|
[:wallet/wizard-navigate-forward
|
||||||
|
@ -420,8 +413,7 @@
|
||||||
{:wallet {:ui {:send {:other-props :value
|
{:wallet {:ui {:send {:other-props :value
|
||||||
:tx-type tx-type
|
:tx-type tx-type
|
||||||
:collectible collectible}}}
|
:collectible collectible}}}
|
||||||
:profile/profile {:test-networks-enabled? testnet-enabled?
|
:profile/profile {:test-networks-enabled? testnet-enabled?}})
|
||||||
:is-goerli-enabled? goerli-enabled?}})
|
|
||||||
(is (match? expected-result
|
(is (match? expected-result
|
||||||
(dispatch [event-id
|
(dispatch [event-id
|
||||||
{:address address
|
{:address address
|
||||||
|
|
|
@ -29,7 +29,6 @@
|
||||||
(update network :full-name #(str % " " testnet-name)))]
|
(update network :full-name #(str % " " testnet-name)))]
|
||||||
(condp #(contains? %1 %2) (:chain-id network)
|
(condp #(contains? %1 %2) (:chain-id network)
|
||||||
constants/sepolia-chain-ids (add-testnet-name constants/sepolia-full-name)
|
constants/sepolia-chain-ids (add-testnet-name constants/sepolia-full-name)
|
||||||
constants/goerli-chain-ids (add-testnet-name constants/goerli-full-name)
|
|
||||||
network)))
|
network)))
|
||||||
|
|
||||||
(defn chain-id->network-details
|
(defn chain-id->network-details
|
||||||
|
@ -47,7 +46,7 @@
|
||||||
js/parseInt))
|
js/parseInt))
|
||||||
chains))]
|
chains))]
|
||||||
(if testnet-mode?
|
(if testnet-mode?
|
||||||
(set/subset? chain-ids (set/union constants/sepolia-chain-ids constants/goerli-chain-ids))
|
(set/subset? chain-ids constants/sepolia-chain-ids)
|
||||||
(set/subset? chain-ids constants/mainnet-chain-ids))))
|
(set/subset? chain-ids constants/mainnet-chain-ids))))
|
||||||
|
|
||||||
(defn get-proposal-networks
|
(defn get-proposal-networks
|
||||||
|
|
|
@ -136,12 +136,6 @@
|
||||||
(fn [profile]
|
(fn [profile]
|
||||||
(:universal-profile-url profile)))
|
(:universal-profile-url profile)))
|
||||||
|
|
||||||
(re-frame/reg-sub
|
|
||||||
:profile/is-goerli-enabled?
|
|
||||||
:<- [:profile/profile]
|
|
||||||
(fn [profile]
|
|
||||||
(:is-goerli-enabled? profile)))
|
|
||||||
|
|
||||||
(re-frame/reg-sub
|
(re-frame/reg-sub
|
||||||
:profile/peer-syncing-enabled?
|
:profile/peer-syncing-enabled?
|
||||||
:<- [:profile/profile]
|
:<- [:profile/profile]
|
||||||
|
|
|
@ -253,12 +253,10 @@
|
||||||
:wallet/selected-networks->chain-ids
|
:wallet/selected-networks->chain-ids
|
||||||
:<- [:wallet/selected-networks]
|
:<- [:wallet/selected-networks]
|
||||||
:<- [:profile/test-networks-enabled?]
|
:<- [:profile/test-networks-enabled?]
|
||||||
:<- [:profile/is-goerli-enabled?]
|
(fn [[selected-networks testnet-enabled?]]
|
||||||
(fn [[selected-networks testnet-enabled? goerli-enabled?]]
|
|
||||||
(set (map #(network-utils/network->chain-id
|
(set (map #(network-utils/network->chain-id
|
||||||
{:network %
|
{:network %
|
||||||
:testnet-enabled? testnet-enabled?
|
:testnet-enabled? testnet-enabled?})
|
||||||
:goerli-enabled? goerli-enabled?})
|
|
||||||
selected-networks))))
|
selected-networks))))
|
||||||
|
|
||||||
(defn- format-settings-keypair-accounts
|
(defn- format-settings-keypair-accounts
|
||||||
|
|
|
@ -122,10 +122,6 @@
|
||||||
:ens-name "test.eth"
|
:ens-name "test.eth"
|
||||||
:chain-id constants/ethereum-mainnet-chain-id
|
:chain-id constants/ethereum-mainnet-chain-id
|
||||||
:expected-result "0xeefb13c7d42efcc655e528da6d6f7bbcf9a2251d"}
|
:expected-result "0xeefb13c7d42efcc655e528da6d6f7bbcf9a2251d"}
|
||||||
{:description "Test on Goerli testnet"
|
|
||||||
:ens-name "qoqobolo.stateofus.eth"
|
|
||||||
:chain-id constants/ethereum-goerli-chain-id
|
|
||||||
:expected-result "0xf8f4f6b5c73f4fb561eb2676326d81b7aba180b0"}
|
|
||||||
{:description "Test on Sepolia testnet"
|
{:description "Test on Sepolia testnet"
|
||||||
:ens-name "code.eth"
|
:ens-name "code.eth"
|
||||||
:chain-id constants/ethereum-sepolia-chain-id
|
:chain-id constants/ethereum-sepolia-chain-id
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
;; this is the addresses of ens registries for the different networks
|
;; this is the addresses of ens registries for the different networks
|
||||||
(def ens-registries
|
(def ens-registries
|
||||||
{:mainnet "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"
|
{:mainnet "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"
|
||||||
:goerli "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"})
|
:sepolia "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"})
|
||||||
|
|
||||||
(def default-address "0x0000000000000000000000000000000000000000")
|
(def default-address "0x0000000000000000000000000000000000000000")
|
||||||
(def default-key
|
(def default-key
|
||||||
|
|
|
@ -26,15 +26,6 @@
|
||||||
(when (and name (string/ends-with? name domain))
|
(when (and name (string/ends-with? name domain))
|
||||||
(first (string/split name "."))))
|
(first (string/split name "."))))
|
||||||
|
|
||||||
(def old-registrars
|
|
||||||
(merge
|
|
||||||
{:mainnet "0xDB5ac1a559b02E12F29fC0eC0e37Be8E046DEF49"
|
|
||||||
:goerli "0xD1f7416F91E7Eb93dD96A61F12FC092aD6B67B11"}))
|
|
||||||
|
|
||||||
(defn get-cached-registrar
|
|
||||||
[chain]
|
|
||||||
(get old-registrars chain))
|
|
||||||
|
|
||||||
(defn lower-case?
|
(defn lower-case?
|
||||||
[s]
|
[s]
|
||||||
(when s
|
(when s
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
(def chains
|
(def chains
|
||||||
{:mainnet {:id 1 :name "Mainnet"}
|
{:mainnet {:id 1 :name "Mainnet"}
|
||||||
:xdai {:id 100 :name "xDai"}
|
:xdai {:id 100 :name "xDai"}
|
||||||
:goerli {:id 5 :name "Goerli"}
|
:sepolia {:id 11155111 :name "Sepolia"}
|
||||||
:bsc {:id BSC-mainnet-chain-id
|
:bsc {:id BSC-mainnet-chain-id
|
||||||
:name "BSC"}
|
:name "BSC"}
|
||||||
:bsc-testnet {:id BSC-testnet-chain-id
|
:bsc-testnet {:id BSC-testnet-chain-id
|
||||||
|
@ -37,7 +37,7 @@
|
||||||
|
|
||||||
(defn testnet?
|
(defn testnet?
|
||||||
[id]
|
[id]
|
||||||
(contains? #{(chain-keyword->chain-id :goerli)
|
(contains? #{(chain-keyword->chain-id :sepolia)
|
||||||
(chain-keyword->chain-id :bsc-testnet)}
|
(chain-keyword->chain-id :bsc-testnet)}
|
||||||
id))
|
id))
|
||||||
|
|
||||||
|
|
|
@ -6,18 +6,18 @@
|
||||||
(defn chain-ids-db
|
(defn chain-ids-db
|
||||||
[test-networks-enabled?]
|
[test-networks-enabled?]
|
||||||
{:profile/profile {:test-networks-enabled? test-networks-enabled?}
|
{:profile/profile {:test-networks-enabled? test-networks-enabled?}
|
||||||
:wallet {:networks {:test [{:chain-id 3}
|
:wallet {:networks {:test [{:chain-id 11155111}
|
||||||
{:chain-id 4}
|
{:chain-id 421614}
|
||||||
{:chain-id 5}]
|
{:chain-id 11155420}]
|
||||||
:prod [{:chain-id 1}
|
:prod [{:chain-id 1}
|
||||||
{:chain-id 42161}
|
{:chain-id 42161}
|
||||||
{:chain-id 10}]}}})
|
{:chain-id 10}]}}})
|
||||||
|
|
||||||
(deftest chain-id->chain-keyword-test
|
(deftest chain-id->chain-keyword-test
|
||||||
(is (= (chain/chain-id->chain-keyword 1) :mainnet))
|
(is (= (chain/chain-id->chain-keyword 1) :mainnet))
|
||||||
(is (= (chain/chain-id->chain-keyword 5) :goerli))
|
(is (= (chain/chain-id->chain-keyword 11155111) :sepolia))
|
||||||
(is (= (chain/chain-id->chain-keyword 5777) :custom)))
|
(is (= (chain/chain-id->chain-keyword 5777) :custom)))
|
||||||
|
|
||||||
(deftest chain-ids-test
|
(deftest chain-ids-test
|
||||||
(is (= (chain/chain-ids (chain-ids-db false)) [1 42161 10]))
|
(is (= (chain/chain-ids (chain-ids-db false)) [1 42161 10]))
|
||||||
(is (= (chain/chain-ids (chain-ids-db true)) [3 4 5])))
|
(is (= (chain/chain-ids (chain-ids-db true)) [11155111 421614 11155420])))
|
||||||
|
|
|
@ -111,9 +111,9 @@
|
||||||
:name "Status Network Token"
|
:name "Status Network Token"
|
||||||
:symbol :SNT
|
:symbol :SNT
|
||||||
:decimals 18}}
|
:decimals 18}}
|
||||||
:goerli {"0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"
|
:sepolia {"0xE452027cdEF746c7Cd3DB31CB700428b16cD8E51"
|
||||||
{:address
|
{:address
|
||||||
"0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"
|
"0xE452027cdEF746c7Cd3DB31CB700428b16cD8E51"
|
||||||
:name "Status Test Token"
|
:name "Status Test Token"
|
||||||
:symbol :STT
|
:symbol :STT
|
||||||
:decimals 18}}})
|
:decimals 18}}})
|
||||||
|
|
|
@ -1103,7 +1103,6 @@
|
||||||
"glossary": "Glossary",
|
"glossary": "Glossary",
|
||||||
"go-to": "Go to",
|
"go-to": "Go to",
|
||||||
"go-to-settings": "Go to Settings...",
|
"go-to-settings": "Go to Settings...",
|
||||||
"goerli-testnet-toggle-confirmation": "Are you sure you want to toggle Goerli? This will log you out and you will have to login again.",
|
|
||||||
"got-it": "Got it",
|
"got-it": "Got it",
|
||||||
"grant-face-id-permissions": "To grant the required Face ID permission, please go to your system settings and make sure that Status > Face ID is selected",
|
"grant-face-id-permissions": "To grant the required Face ID permission, please go to your system settings and make sure that Status > Face ID is selected",
|
||||||
"grant-fingerprints-permissions": "To grant the required fingerprints permission, please go to your system settings and make sure that Status > Fingerprints is selected",
|
"grant-fingerprints-permissions": "To grant the required fingerprints permission, please go to your system settings and make sure that Status > Fingerprints is selected",
|
||||||
|
|
Loading…
Reference in New Issue