diff --git a/ci/Jenkinsfile.android b/ci/Jenkinsfile.android index 4ded4bb45d..94f65094f6 100644 --- a/ci/Jenkinsfile.android +++ b/ci/Jenkinsfile.android @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.8.4' +library 'status-jenkins-lib@v1.8.5' /* Options section can't access functions in objects. */ def isPRBuild = utils.isPRBuild() diff --git a/ci/Jenkinsfile.combined b/ci/Jenkinsfile.combined index 3e31b346c7..02eb9e1b83 100644 --- a/ci/Jenkinsfile.combined +++ b/ci/Jenkinsfile.combined @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.8.4' +library 'status-jenkins-lib@v1.8.5' pipeline { agent { label 'linux' } diff --git a/ci/Jenkinsfile.e2e-nightly b/ci/Jenkinsfile.e2e-nightly index e44a6478be..7495d9eee5 100644 --- a/ci/Jenkinsfile.e2e-nightly +++ b/ci/Jenkinsfile.e2e-nightly @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.8.4' +library 'status-jenkins-lib@v1.8.5' pipeline { agent { label 'linux' } diff --git a/ci/Jenkinsfile.ios b/ci/Jenkinsfile.ios index 9d60461791..6b4f800b74 100644 --- a/ci/Jenkinsfile.ios +++ b/ci/Jenkinsfile.ios @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.8.4' +library 'status-jenkins-lib@v1.8.5' /* Options section can't access functions in objects. */ def isPRBuild = utils.isPRBuild() diff --git a/ci/Jenkinsfile.tests b/ci/Jenkinsfile.tests index 19d324c852..ff66437713 100644 --- a/ci/Jenkinsfile.tests +++ b/ci/Jenkinsfile.tests @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.8.4' +library 'status-jenkins-lib@v1.8.5' /* Options section can't access functions in objects. */ def isPRBuild = utils.isPRBuild() diff --git a/ci/tests/Jenkinsfile.e2e-nightly b/ci/tests/Jenkinsfile.e2e-nightly index 1cc0af6d94..439135c4f6 100644 --- a/ci/tests/Jenkinsfile.e2e-nightly +++ b/ci/tests/Jenkinsfile.e2e-nightly @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { diff --git a/ci/tests/Jenkinsfile.e2e-prs b/ci/tests/Jenkinsfile.e2e-prs index 41e28a2e01..a472efe55e 100644 --- a/ci/tests/Jenkinsfile.e2e-prs +++ b/ci/tests/Jenkinsfile.e2e-prs @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { diff --git a/ci/tests/Jenkinsfile.e2e-upgrade b/ci/tests/Jenkinsfile.e2e-upgrade index 944e88eeb8..51b3b5c6b4 100644 --- a/ci/tests/Jenkinsfile.e2e-upgrade +++ b/ci/tests/Jenkinsfile.e2e-upgrade @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { diff --git a/ci/tools/Jenkinsfile.fastlane-clean b/ci/tools/Jenkinsfile.fastlane-clean index b0e810eda2..6b4c1dda35 100644 --- a/ci/tools/Jenkinsfile.fastlane-clean +++ b/ci/tools/Jenkinsfile.fastlane-clean @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { agent { label 'macos' } diff --git a/ci/tools/Jenkinsfile.nix-cache b/ci/tools/Jenkinsfile.nix-cache index cdaca195ad..e4db22adf3 100644 --- a/ci/tools/Jenkinsfile.nix-cache +++ b/ci/tools/Jenkinsfile.nix-cache @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { agent { label params.AGENT_LABEL } diff --git a/ci/tools/Jenkinsfile.playstore-meta b/ci/tools/Jenkinsfile.playstore-meta index c8f429d919..80e0e0f49f 100644 --- a/ci/tools/Jenkinsfile.playstore-meta +++ b/ci/tools/Jenkinsfile.playstore-meta @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { agent { label 'linux' } diff --git a/ci/tools/Jenkinsfile.xcode-clean b/ci/tools/Jenkinsfile.xcode-clean index c7f592972a..52f6d58c6a 100644 --- a/ci/tools/Jenkinsfile.xcode-clean +++ b/ci/tools/Jenkinsfile.xcode-clean @@ -1,5 +1,5 @@ #!/usr/bin/env groovy -library 'status-jenkins-lib@v1.7.15' +library 'status-jenkins-lib@v1.8.5' pipeline { agent { diff --git a/scripts/build-android.sh b/scripts/build-android.sh index cf5b5ae297..fdba77923d 100755 --- a/scripts/build-android.sh +++ b/scripts/build-android.sh @@ -33,10 +33,17 @@ trap "rm -vf ${SECRETS_FILE_PATH}" EXIT ERR INT QUIT # Names of variables containing secrets to save in env file. SECRETS_ENV_VARS=( + 'ALCHEMY_ETHEREUM_MAINNET_TOKEN' + 'ALCHEMY_ETHEREUM_GOERLI_TOKEN' + 'ALCHEMY_ETHEREUM_SEPOLIA_TOKEN' 'ALCHEMY_ARBITRUM_GOERLI_TOKEN' 'ALCHEMY_ARBITRUM_MAINNET_TOKEN' + 'ALCHEMY_ARBITRUM_SEPOLIA_TOKEN' 'ALCHEMY_OPTIMISM_GOERLI_TOKEN' 'ALCHEMY_OPTIMISM_MAINNET_TOKEN' + 'ALCHEMY_OPTIMISM_SEPOLIA_TOKEN' + 'RARIBLE_MAINNET_API_KEY' + 'RARIBLE_TESTNET_API_KEY' 'INFURA_TOKEN' 'INFURA_TOKEN_SECRET' 'OPENSEA_API_KEY' diff --git a/shadow-cljs.edn b/shadow-cljs.edn index 634110408e..ad0e115585 100644 --- a/shadow-cljs.edn +++ b/shadow-cljs.edn @@ -63,10 +63,17 @@ {status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN" status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN" status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_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/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_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_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_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_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_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"} :compiler-options {:output-feature-set :es5 ;; We disable `:fn-deprecated` warnings because we ;; are managing deprecation via clj-kondo and we @@ -90,10 +97,17 @@ {status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN" status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN" status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_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/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_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_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_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_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_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"} :compiler-options {:output-feature-set :es6 ;;disable for android build as there ;;is an intermittent warning with deftype @@ -123,10 +137,17 @@ status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN" status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN" status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_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/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_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_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_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_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_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"} :compiler-options {;; needed because we override require and it ;; messes with source-map which reports callstack diff --git a/src/legacy/status_im/ui/screens/advanced_settings/views.cljs b/src/legacy/status_im/ui/screens/advanced_settings/views.cljs index c4c6b41ba9..b1b51bf96b 100644 --- a/src/legacy/status_im/ui/screens/advanced_settings/views.cljs +++ b/src/legacy/status_im/ui/screens/advanced_settings/views.cljs @@ -19,7 +19,8 @@ transactions-management-enabled? current-fleet webview-debug - test-networks-enabled?]}] + test-networks-enabled? + is-sepolia-enabled?]}] (keep identity [{:size :small @@ -110,6 +111,14 @@ #(re-frame/dispatch [:profile.settings/toggle-test-networks]) :accessory :switch :active test-networks-enabled?} + {:size :small + :title "Enable Sepolia as test network" + :accessibility-label :enable-sepolia-as-test-network + :container-margin-bottom 8 + :on-press + #(re-frame/dispatch [:profile.settings/toggle-sepolia-test-network]) + :accessory :switch + :active is-sepolia-enabled?} {:size :small :title (i18n/label :t/set-currency) :accessibility-label :wallet-change-currency @@ -130,6 +139,7 @@ (views/defview advanced-settings [] (views/letsubs [test-networks-enabled? [:profile/test-networks-enabled?] + is-sepolia-enabled? [:profile/is-sepolia-enabled?] light-client-enabled? [:profile/light-client-enabled?] webview-debug [:profile/webview-debug] network-name [:network-name] @@ -145,6 +155,7 @@ :current-fleet current-fleet :dev-mode? false :webview-debug webview-debug - :test-networks-enabled? test-networks-enabled?}) + :test-networks-enabled? test-networks-enabled? + :is-sepolia-enabled? is-sepolia-enabled?}) :key-fn (fn [_ i] (str i)) :render-fn render-item}])) diff --git a/src/status_im/config.cljs b/src/status_im/config.cljs index d68fc18656..71a3458ce0 100644 --- a/src/status_im/config.cljs +++ b/src/status_im/config.cljs @@ -11,11 +11,18 @@ (goog-define INFURA_TOKEN "") (goog-define POKT_TOKEN "3ef2018191814b7e1009b8d9") -(goog-define ALCHEMY_ARBITRUM_GOERLI_TOKEN "") -(goog-define ALCHEMY_OPTIMISM_GOERLI_TOKEN "") -(goog-define ALCHEMY_OPTIMISM_MAINNET_TOKEN "") -(goog-define ALCHEMY_ARBITRUM_MAINNET_TOKEN "") (goog-define OPENSEA_API_KEY "") +(goog-define RARIBLE_MAINNET_API_KEY "") +(goog-define RARIBLE_TESTNET_API_KEY "") +(goog-define ALCHEMY_ETHEREUM_MAINNET_TOKEN "") +(goog-define ALCHEMY_ETHEREUM_GOERLI_TOKEN "") +(goog-define ALCHEMY_ETHEREUM_SEPOLIA_TOKEN "") +(goog-define ALCHEMY_ARBITRUM_MAINNET_TOKEN "") +(goog-define ALCHEMY_ARBITRUM_GOERLI_TOKEN "") +(goog-define ALCHEMY_ARBITRUM_SEPOLIA_TOKEN "") +(goog-define ALCHEMY_OPTIMISM_MAINNET_TOKEN "") +(goog-define ALCHEMY_OPTIMISM_GOERLI_TOKEN "") +(goog-define ALCHEMY_OPTIMISM_SEPOLIA_TOKEN "") (def mainnet-rpc-url (str "https://eth-archival.gateway.pokt.network/v1/lb/" POKT_TOKEN)) (def goerli-rpc-url (str "https://goerli-archival.gateway.pokt.network/v1/lb/" POKT_TOKEN)) diff --git a/src/status_im/constants.cljs b/src/status_im/constants.cljs index dbf1719451..5b24acd0a1 100644 --- a/src/status_im/constants.cljs +++ b/src/status_im/constants.cljs @@ -410,12 +410,15 @@ (def ^:const ens-action-type-set-pub-key 2) ;; wallet -(def ^:const mainnet-chain-id 1) -(def ^:const optimism-chain-id 10) -(def ^:const optimism-test-chain-id 420) -(def ^:const arbitrum-chain-id 42161) -(def ^:const arbitrum-test-chain-id 421613) -(def ^:const goerli-chain-id 5) +(def ^:const ethereum-mainnet-chain-id 1) +(def ^:const ethereum-goerli-chain-id 5) +(def ^:const ethereum-sepolia-chain-id 11155111) +(def ^:const arbitrum-mainnet-chain-id 42161) +(def ^:const arbitrum-goerli-chain-id 421613) +(def ^:const arbitrum-sepolia-chain-id 421614) +(def ^:const optimism-mainnet-chain-id 10) +(def ^:const optimism-goerli-chain-id 420) +(def ^:const optimism-sepolia-chain-id 11155420) (def ^:const mainnet-short-name "eth") (def ^:const optimism-short-name "opt") diff --git a/src/status_im/contexts/profile/config.cljs b/src/status_im/contexts/profile/config.cljs index 391c46769d..137f97df5e 100644 --- a/src/status_im/contexts/profile/config.cljs +++ b/src/status_im/contexts/profile/config.cljs @@ -13,10 +13,17 @@ :openseaAPIKey config/opensea-api-key :poktToken config/POKT_TOKEN :infuraToken config/INFURA_TOKEN + :raribleMainnetAPIKey config/RARIBLE_MAINNET_API_KEY + :raribleTestnetAPIKey config/RARIBLE_TESTNET_API_KEY + :alchemyEthereumMainnetToken config/ALCHEMY_ETHEREUM_MAINNET_TOKEN + :alchemyEthereumGoerliToken config/ALCHEMY_ETHEREUM_GOERLI_TOKEN + :alchemyEthereumSepoliaToken config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN :alchemyOptimismMainnetToken config/ALCHEMY_OPTIMISM_MAINNET_TOKEN :alchemyOptimismGoerliToken config/ALCHEMY_OPTIMISM_GOERLI_TOKEN + :alchemyOptimismSepoliaToken config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN :alchemyArbitrumMainnetToken config/ALCHEMY_ARBITRUM_MAINNET_TOKEN - :alchemyArbitrumGoerliToken config/ALCHEMY_ARBITRUM_GOERLI_TOKEN}) + :alchemyArbitrumGoerliToken config/ALCHEMY_ARBITRUM_GOERLI_TOKEN + :alchemyArbitrumSepoliaToken config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN}) (defn create [] diff --git a/src/status_im/contexts/profile/settings/events.cljs b/src/status_im/contexts/profile/settings/events.cljs index 35e8c43d72..58f0526bcb 100644 --- a/src/status_im/contexts/profile/settings/events.cljs +++ b/src/status_im/contexts/profile/settings/events.cljs @@ -70,6 +70,15 @@ {:on-success on-success}]) :on-cancel nil}]]}))) +(rf/reg-event-fx :profile.settings/toggle-sepolia-test-network + (fn [{:keys [db]}] + (let [value (get-in db [:profile/profile :is-sepolia-enabled?]) + on-success #(rf/dispatch [:wallet/initialize])] + {:fx [[:dispatch + [:profile.settings/profile-update :is-sepolia-enabled? + (not value) + {:on-success on-success}]]]}))) + (rf/defn change-preview-privacy-flag {:events [:profile.settings/change-preview-privacy]} [{:keys [db] :as cofx} private?] @@ -80,7 +89,6 @@ (boolean private?) {}))) - (rf/defn change-profile-pictures-show-to {:events [:profile.settings/change-profile-pictures-show-to]} [cofx id] diff --git a/src/status_im/contexts/wallet/common/utils.cljs b/src/status_im/contexts/wallet/common/utils.cljs index 1141af9e9a..d39e84e97c 100644 --- a/src/status_im/contexts/wallet/common/utils.cljs +++ b/src/status_im/contexts/wallet/common/utils.cljs @@ -190,17 +190,20 @@ address)) (def id->network - {constants/mainnet-chain-id :ethereum - constants/goerli-chain-id :ethereum - constants/optimism-chain-id :optimism - constants/optimism-test-chain-id :optimism - constants/arbitrum-chain-id :arbitrum - constants/arbitrum-test-chain-id :arbitrum}) + {constants/ethereum-mainnet-chain-id :ethereum + constants/ethereum-goerli-chain-id :ethereum + constants/ethereum-sepolia-chain-id :ethereum + constants/optimism-mainnet-chain-id :optimism + constants/optimism-goerli-chain-id :optimism + constants/optimism-sepolia-chain-id :optimism + constants/arbitrum-mainnet-chain-id :arbitrum + constants/arbitrum-goerli-chain-id :arbitrum + constants/arbitrum-sepolia-chain-id :arbitrum}) (def short-name->id - {:eth constants/mainnet-chain-id - :opt constants/optimism-chain-id - :arb1 constants/arbitrum-chain-id}) + {:eth constants/ethereum-mainnet-chain-id + :opt constants/optimism-mainnet-chain-id + :arb1 constants/arbitrum-mainnet-chain-id}) (defn get-standard-fiat-format [crypto-value currency-symbol fiat-value] diff --git a/src/status_im/subs/profile.cljs b/src/status_im/subs/profile.cljs index 070f13317c..195dbeb180 100644 --- a/src/status_im/subs/profile.cljs +++ b/src/status_im/subs/profile.cljs @@ -106,6 +106,12 @@ (fn [profile] (:test-networks-enabled? profile))) +(re-frame/reg-sub + :profile/is-sepolia-enabled? + :<- [:profile/profile] + (fn [profile] + (:is-sepolia-enabled? profile))) + (re-frame/reg-sub :multiaccount/contact :<- [:profile/profile] diff --git a/src/status_im/subs/wallet/networks.cljs b/src/status_im/subs/wallet/networks.cljs index 580258d7bc..0d1c5c9d22 100644 --- a/src/status_im/subs/wallet/networks.cljs +++ b/src/status_im/subs/wallet/networks.cljs @@ -30,11 +30,22 @@ :short-name constants/optimism-short-name :network-name constants/optimism-network-name}) -(def network-list - {constants/mainnet-chain-id mainnet-network-details - constants/goerli-chain-id mainnet-network-details - constants/arbitrum-chain-id arbitrum-network-details - constants/optimism-chain-id optimism-network-details}) +(defn get-network-details + [chain-id] + (case chain-id + (constants/ethereum-mainnet-chain-id constants/ethereum-goerli-chain-id + constants/ethereum-sepolia-chain-id) + mainnet-network-details + + (constants/arbitrum-mainnet-chain-id constants/arbitrum-goerli-chain-id + constants/arbitrum-sepolia-chain-id) + arbitrum-network-details + + (constants/optimism-mainnet-chain-id constants/optimism-goerli-chain-id + constants/optimism-sepolia-chain-id) + optimism-network-details + + nil)) (re-frame/reg-sub :wallet/network-details @@ -43,7 +54,7 @@ (->> networks (keep (fn [{:keys [chain-id related-chain-id layer test?]}] - (let [network-details (get network-list (if test? related-chain-id chain-id))] + (let [network-details (get-network-details (if test? related-chain-id chain-id))] (assoc network-details :chain-id chain-id :related-chain-id related-chain-id diff --git a/status-go-version.json b/status-go-version.json index 40acc054b4..c055e46c48 100644 --- a/status-go-version.json +++ b/status-go-version.json @@ -3,7 +3,7 @@ "_comment": "Instead use: scripts/update-status-go.sh ", "owner": "status-im", "repo": "status-go", - "version": "v0.172.11", - "commit-sha1": "9879b1ea7701c40d9f9cdbe67251242452b8d2e3", - "src-sha256": "147yx2dgjdalxpryq558qlmdl2aaa1vfpdyblzdyj3gd5291yck3" + "version": "v0.173.0", + "commit-sha1": "b83cd418af77ec8dabe3849bf51984a4232740d9", + "src-sha256": "00w8kqdkrv9x95dmlxy7zdm70vilh0gpnj6n81hg1124dy4gwikd" }