Skip to content

Commit 3dfef03

Browse files
bertllllBert
authored andcommitted
GH-781: New Testnet Polygon Amoy (#431)
* GH-781: experimenting with a test utility * GH-781: task might be complete now * GH-781: debugging for windows * GH-781: trying to satisfy Win * GH-781: clippy * GH-781: removed bad solution for issue that now a new card was written for * GH-781: cargo.toml change * GH-781: review answered --------- Co-authored-by: Bert <[email protected]>
1 parent b0f9e02 commit 3dfef03

27 files changed

+290
-253
lines changed

masq/src/commands/configuration_command.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ mod tests {
413413
blockchain_service_url_opt: Some("https://infura.io/ID".to_string()),
414414
current_schema_version: "schema version".to_string(),
415415
clandestine_port: 1234,
416-
chain_name: "mumbai".to_string(),
416+
chain_name: "amoy".to_string(),
417417
gas_price: 2345,
418418
max_block_count_opt: Some(100_000),
419419
neighborhood_mode: "zero-hop".to_string(),
@@ -470,7 +470,7 @@ mod tests {
470470
"\
471471
|NAME VALUE\n\
472472
|Blockchain service URL: https://infura.io/ID\n\
473-
|Chain: mumbai\n\
473+
|Chain: amoy\n\
474474
|Clandestine port: 1234\n\
475475
|Consuming wallet private key: [?]\n\
476476
|Current schema version: schema version\n\

masq/src/commands/setup_command.rs

+7-7
Original file line numberDiff line numberDiff line change
@@ -391,10 +391,10 @@ ip No sir, I don't like it.\n\
391391
status_data_dir: UiSetupResponseValueStatus::Default,
392392
},
393393
SetupCommandData {
394-
chain_str: Some("polygon-mumbai".to_owned()),
394+
chain_str: Some("polygon-amoy".to_owned()),
395395
data_directory: None,
396-
chain_name_expected: Some("polygon-mumbai"),
397-
data_directory_expected: Some("/home/cooga/.local/MASQ/polygon-mumbai"),
396+
chain_name_expected: Some("polygon-amoy"),
397+
data_directory_expected: Some("/home/cooga/.local/MASQ/polygon-amoy"),
398398
note_expected: true,
399399
status_chain: UiSetupResponseValueStatus::Set,
400400
status_data_dir: UiSetupResponseValueStatus::Default,
@@ -409,10 +409,10 @@ ip No sir, I don't like it.\n\
409409
status_data_dir: UiSetupResponseValueStatus::Set,
410410
},
411411
SetupCommandData {
412-
chain_str: Some("polygon-mumbai".to_owned()),
413-
data_directory: Some("booga/polygon-mumbai".to_owned()),
414-
chain_name_expected: Some("polygon-mumbai"),
415-
data_directory_expected: Some("booga/polygon-mumbai/polygon-mumbai"),
412+
chain_str: Some("polygon-amoy".to_owned()),
413+
data_directory: Some("booga/polygon-amoy".to_owned()),
414+
chain_name_expected: Some("polygon-amoy"),
415+
data_directory_expected: Some("booga/polygon-amoy/polygon-amoy"),
416416
note_expected: true,
417417
status_chain: UiSetupResponseValueStatus::Set,
418418
status_data_dir: UiSetupResponseValueStatus::Set,

masq_lib/src/blockchains/blockchain_records.rs

+36-39
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,14 @@
22

33
use crate::blockchains::chains::Chain;
44
use crate::constants::{
5-
DEV_CHAIN_FULL_IDENTIFIER, ETH_MAINNET_CONTRACT_CREATION_BLOCK, ETH_MAINNET_FULL_IDENTIFIER,
6-
ETH_ROPSTEN_FULL_IDENTIFIER, MULTINODE_TESTNET_CONTRACT_CREATION_BLOCK,
7-
MUMBAI_TESTNET_CONTRACT_CREATION_BLOCK, POLYGON_MAINNET_CONTRACT_CREATION_BLOCK,
8-
POLYGON_MAINNET_FULL_IDENTIFIER, POLYGON_MUMBAI_FULL_IDENTIFIER,
5+
AMOY_TESTNET_CONTRACT_CREATION_BLOCK, DEV_CHAIN_FULL_IDENTIFIER,
6+
ETH_MAINNET_CONTRACT_CREATION_BLOCK, ETH_MAINNET_FULL_IDENTIFIER, ETH_ROPSTEN_FULL_IDENTIFIER,
7+
MULTINODE_TESTNET_CONTRACT_CREATION_BLOCK, POLYGON_AMOY_FULL_IDENTIFIER,
8+
POLYGON_MAINNET_CONTRACT_CREATION_BLOCK, POLYGON_MAINNET_FULL_IDENTIFIER,
99
ROPSTEN_TESTNET_CONTRACT_CREATION_BLOCK,
1010
};
1111
use ethereum_types::{Address, H160};
1212

13-
//chains are ordered by their significance for the community of users (the order reflects in some error or help messages)
1413
pub const CHAINS: [BlockchainRecord; 5] = [
1514
BlockchainRecord {
1615
self_id: Chain::PolyMainnet,
@@ -27,11 +26,11 @@ pub const CHAINS: [BlockchainRecord; 5] = [
2726
contract_creation_block: ETH_MAINNET_CONTRACT_CREATION_BLOCK,
2827
},
2928
BlockchainRecord {
30-
self_id: Chain::PolyMumbai,
31-
num_chain_id: 80001,
32-
literal_identifier: POLYGON_MUMBAI_FULL_IDENTIFIER,
33-
contract: MUMBAI_TESTNET_CONTRACT_ADDRESS,
34-
contract_creation_block: MUMBAI_TESTNET_CONTRACT_CREATION_BLOCK,
29+
self_id: Chain::PolyAmoy,
30+
num_chain_id: 80002,
31+
literal_identifier: POLYGON_AMOY_FULL_IDENTIFIER,
32+
contract: AMOY_TESTNET_CONTRACT_ADDRESS,
33+
contract_creation_block: AMOY_TESTNET_CONTRACT_CREATION_BLOCK,
3534
},
3635
BlockchainRecord {
3736
self_id: Chain::EthRopsten,
@@ -58,6 +57,22 @@ pub struct BlockchainRecord {
5857
pub contract_creation_block: u64,
5958
}
6059

60+
const POLYGON_MAINNET_CONTRACT_ADDRESS: Address = H160([
61+
0xee, 0x9a, 0x35, 0x2f, 0x6a, 0xac, 0x4a, 0xf1, 0xa5, 0xb9, 0xf4, 0x67, 0xf6, 0xa9, 0x3e, 0x0f,
62+
0xfb, 0xe9, 0xdd, 0x35,
63+
]);
64+
65+
const ETH_MAINNET_CONTRACT_ADDRESS: Address = H160([
66+
0x06, 0xf3, 0xc3, 0x23, 0xf0, 0x23, 0x8c, 0x72, 0xbf, 0x35, 0x01, 0x10, 0x71, 0xf2, 0xb5, 0xb7,
67+
0xf4, 0x3a, 0x05, 0x4c,
68+
]);
69+
70+
// $tMASQ (Amoy)
71+
const AMOY_TESTNET_CONTRACT_ADDRESS: Address = H160([
72+
0xd9, 0x8c, 0x3e, 0xbd, 0x6b, 0x7f, 0x9b, 0x7c, 0xda, 0x24, 0x49, 0xec, 0xac, 0x00, 0xd1, 0xe5,
73+
0xf4, 0x7a, 0x81, 0x93,
74+
]);
75+
6176
// SHRD (Ropsten)
6277
const ROPSTEN_TESTNET_CONTRACT_ADDRESS: Address = H160([
6378
0x38, 0x4d, 0xec, 0x25, 0xe0, 0x3f, 0x94, 0x93, 0x17, 0x67, 0xce, 0x4c, 0x35, 0x56, 0x16, 0x84,
@@ -69,30 +84,12 @@ const MULTINODE_TESTNET_CONTRACT_ADDRESS: Address = H160([
6984
0xf1, 0xb3, 0xe6, 0x64,
7085
]);
7186

72-
const ETH_MAINNET_CONTRACT_ADDRESS: Address = H160([
73-
0x06, 0xF3, 0xC3, 0x23, 0xf0, 0x23, 0x8c, 0x72, 0xBF, 0x35, 0x01, 0x10, 0x71, 0xf2, 0xb5, 0xB7,
74-
0xF4, 0x3A, 0x05, 0x4c,
75-
]);
76-
77-
#[allow(clippy::mixed_case_hex_literals)]
78-
const POLYGON_MAINNET_CONTRACT_ADDRESS: Address = H160([
79-
0xEe, 0x9A, 0x35, 0x2F, 0x6a, 0xAc, 0x4a, 0xF1, 0xA5, 0xB9, 0xf4, 0x67, 0xF6, 0xa9, 0x3E, 0x0f,
80-
0xfB, 0xe9, 0xDd, 0x35,
81-
]);
82-
83-
// $tMASQ (Mumbai)
84-
#[allow(clippy::mixed_case_hex_literals)]
85-
const MUMBAI_TESTNET_CONTRACT_ADDRESS: Address = H160([
86-
0x9B, 0x27, 0x03, 0x4a, 0xca, 0xBd, 0x44, 0x22, 0x3f, 0xB2, 0x3d, 0x62, 0x8B, 0xa4, 0x84, 0x98,
87-
0x67, 0xcE, 0x1D, 0xB2,
88-
]);
89-
9087
#[cfg(test)]
9188
mod tests {
9289
use super::*;
9390
use crate::blockchains::chains::chain_from_chain_identifier_opt;
9491
use crate::constants::{
95-
MUMBAI_TESTNET_CONTRACT_CREATION_BLOCK, POLYGON_MAINNET_CONTRACT_CREATION_BLOCK,
92+
AMOY_TESTNET_CONTRACT_CREATION_BLOCK, POLYGON_MAINNET_CONTRACT_CREATION_BLOCK,
9693
};
9794
use std::collections::HashSet;
9895
use std::iter::FromIterator;
@@ -104,7 +101,7 @@ mod tests {
104101
assert_returns_correct_record(Chain::Dev, 2),
105102
assert_returns_correct_record(Chain::EthRopsten, 3),
106103
assert_returns_correct_record(Chain::PolyMainnet, 137),
107-
assert_returns_correct_record(Chain::PolyMumbai, 80001),
104+
assert_returns_correct_record(Chain::PolyAmoy, 80002),
108105
];
109106
assert_exhaustive(&test_array)
110107
}
@@ -118,7 +115,7 @@ mod tests {
118115
fn from_str_works() {
119116
let test_array = [
120117
assert_from_str(Chain::PolyMainnet),
121-
assert_from_str(Chain::PolyMumbai),
118+
assert_from_str(Chain::PolyAmoy),
122119
assert_from_str(Chain::EthMainnet),
123120
assert_from_str(Chain::EthRopsten),
124121
assert_from_str(Chain::Dev),
@@ -142,7 +139,7 @@ mod tests {
142139
let test_array = [
143140
assert_chain_significance(0, Chain::PolyMainnet),
144141
assert_chain_significance(1, Chain::EthMainnet),
145-
assert_chain_significance(2, Chain::PolyMumbai),
142+
assert_chain_significance(2, Chain::PolyAmoy),
146143
assert_chain_significance(3, Chain::EthRopsten),
147144
assert_chain_significance(4, Chain::Dev),
148145
];
@@ -203,17 +200,17 @@ mod tests {
203200
}
204201

205202
#[test]
206-
fn mumbai_record_is_properly_declared() {
207-
let examined_chain = Chain::PolyMumbai;
203+
fn amoy_record_is_properly_declared() {
204+
let examined_chain = Chain::PolyAmoy;
208205
let chain_record = return_examined(examined_chain);
209206
assert_eq!(
210207
chain_record,
211208
&BlockchainRecord {
212-
num_chain_id: 80001,
209+
num_chain_id: 80002,
213210
self_id: examined_chain,
214-
literal_identifier: "polygon-mumbai",
215-
contract: MUMBAI_TESTNET_CONTRACT_ADDRESS,
216-
contract_creation_block: MUMBAI_TESTNET_CONTRACT_CREATION_BLOCK,
211+
literal_identifier: "polygon-amoy",
212+
contract: AMOY_TESTNET_CONTRACT_ADDRESS,
213+
contract_creation_block: AMOY_TESTNET_CONTRACT_CREATION_BLOCK,
217214
}
218215
);
219216
}
@@ -245,7 +242,7 @@ mod tests {
245242
assert_chain_from_chain_identifier_opt("eth-ropsten", Some(Chain::EthRopsten)),
246243
assert_chain_from_chain_identifier_opt("dev", Some(Chain::Dev)),
247244
assert_chain_from_chain_identifier_opt("polygon-mainnet", Some(Chain::PolyMainnet)),
248-
assert_chain_from_chain_identifier_opt("polygon-mumbai", Some(Chain::PolyMumbai)),
245+
assert_chain_from_chain_identifier_opt("polygon-amoy", Some(Chain::PolyAmoy)),
249246
];
250247
assert_exhaustive(&test_array)
251248
}

masq_lib/src/blockchains/chains.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use crate::blockchains::blockchain_records::{BlockchainRecord, CHAINS};
44
use crate::constants::{
55
DEFAULT_CHAIN, DEV_CHAIN_FULL_IDENTIFIER, ETH_MAINNET_FULL_IDENTIFIER,
6-
ETH_ROPSTEN_FULL_IDENTIFIER, POLYGON_MAINNET_FULL_IDENTIFIER, POLYGON_MUMBAI_FULL_IDENTIFIER,
6+
ETH_ROPSTEN_FULL_IDENTIFIER, POLYGON_AMOY_FULL_IDENTIFIER, POLYGON_MAINNET_FULL_IDENTIFIER,
77
};
88
use serde_derive::{Deserialize, Serialize};
99

@@ -12,7 +12,7 @@ pub enum Chain {
1212
EthMainnet,
1313
EthRopsten,
1414
PolyMainnet,
15-
PolyMumbai,
15+
PolyAmoy,
1616
Dev,
1717
}
1818

@@ -28,8 +28,8 @@ impl From<&str> for Chain {
2828
Chain::PolyMainnet
2929
} else if str == ETH_MAINNET_FULL_IDENTIFIER {
3030
Chain::EthMainnet
31-
} else if str == POLYGON_MUMBAI_FULL_IDENTIFIER {
32-
Chain::PolyMumbai
31+
} else if str == POLYGON_AMOY_FULL_IDENTIFIER {
32+
Chain::PolyAmoy
3333
} else if str == ETH_ROPSTEN_FULL_IDENTIFIER {
3434
Chain::EthRopsten
3535
} else if str == DEV_CHAIN_FULL_IDENTIFIER {

masq_lib/src/constants.rs

+10-10
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ pub const WEIS_IN_GWEI: i128 = 1_000_000_000;
2626

2727
pub const ETH_MAINNET_CONTRACT_CREATION_BLOCK: u64 = 11_170_708;
2828
pub const ROPSTEN_TESTNET_CONTRACT_CREATION_BLOCK: u64 = 8_688_171;
29-
pub const MULTINODE_TESTNET_CONTRACT_CREATION_BLOCK: u64 = 0;
3029
pub const POLYGON_MAINNET_CONTRACT_CREATION_BLOCK: u64 = 14_863_650;
31-
pub const MUMBAI_TESTNET_CONTRACT_CREATION_BLOCK: u64 = 24_638_838;
30+
pub const AMOY_TESTNET_CONTRACT_CREATION_BLOCK: u64 = 5_323_366;
31+
pub const MULTINODE_TESTNET_CONTRACT_CREATION_BLOCK: u64 = 0;
3232

3333
//Migration versions
3434
////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -87,15 +87,15 @@ pub const CENTRAL_DELIMITER: char = '@';
8787
pub const CHAIN_IDENTIFIER_DELIMITER: char = ':';
8888

8989
//chains
90-
const MAINNET: &str = "mainnet";
9190
const POLYGON_FAMILY: &str = "polygon";
9291
const ETH_FAMILY: &str = "eth";
92+
const MAINNET: &str = "mainnet";
9393
const LINK: char = '-';
9494
pub const POLYGON_MAINNET_FULL_IDENTIFIER: &str = concatcp!(POLYGON_FAMILY, LINK, MAINNET);
95-
pub const POLYGON_MUMBAI_FULL_IDENTIFIER: &str = concatcp!(POLYGON_FAMILY, LINK, "mumbai");
96-
pub const DEV_CHAIN_FULL_IDENTIFIER: &str = "dev";
95+
pub const POLYGON_AMOY_FULL_IDENTIFIER: &str = concatcp!(POLYGON_FAMILY, LINK, "amoy");
9796
pub const ETH_MAINNET_FULL_IDENTIFIER: &str = concatcp!(ETH_FAMILY, LINK, MAINNET);
9897
pub const ETH_ROPSTEN_FULL_IDENTIFIER: &str = concatcp!(ETH_FAMILY, LINK, "ropsten");
98+
pub const DEV_CHAIN_FULL_IDENTIFIER: &str = "dev";
9999

100100
#[cfg(test)]
101101
mod tests {
@@ -119,9 +119,9 @@ mod tests {
119119
assert_eq!(WEIS_IN_GWEI, 1_000_000_000);
120120
assert_eq!(ETH_MAINNET_CONTRACT_CREATION_BLOCK, 11_170_708);
121121
assert_eq!(ROPSTEN_TESTNET_CONTRACT_CREATION_BLOCK, 8_688_171);
122-
assert_eq!(MULTINODE_TESTNET_CONTRACT_CREATION_BLOCK, 0);
123122
assert_eq!(POLYGON_MAINNET_CONTRACT_CREATION_BLOCK, 14_863_650);
124-
assert_eq!(MUMBAI_TESTNET_CONTRACT_CREATION_BLOCK, 24_638_838);
123+
assert_eq!(AMOY_TESTNET_CONTRACT_CREATION_BLOCK, 5_323_366);
124+
assert_eq!(MULTINODE_TESTNET_CONTRACT_CREATION_BLOCK, 0);
125125
assert_eq!(CONFIGURATOR_PREFIX, 0x0001_0000_0000_0000);
126126
assert_eq!(CONFIGURATOR_READ_ERROR, CONFIGURATOR_PREFIX | 1);
127127
assert_eq!(CONFIGURATOR_WRITE_ERROR, CONFIGURATOR_PREFIX | 2);
@@ -157,15 +157,15 @@ mod tests {
157157
assert_eq!(VALUE_EXCEEDS_ALLOWED_LIMIT, ACCOUNTANT_PREFIX | 3);
158158
assert_eq!(CENTRAL_DELIMITER, '@');
159159
assert_eq!(CHAIN_IDENTIFIER_DELIMITER, ':');
160-
assert_eq!(MAINNET, "mainnet");
161160
assert_eq!(POLYGON_FAMILY, "polygon");
162161
assert_eq!(ETH_FAMILY, "eth");
162+
assert_eq!(MAINNET, "mainnet");
163163
assert_eq!(LINK, '-');
164164
assert_eq!(POLYGON_MAINNET_FULL_IDENTIFIER, "polygon-mainnet");
165-
assert_eq!(POLYGON_MUMBAI_FULL_IDENTIFIER, "polygon-mumbai");
166-
assert_eq!(DEV_CHAIN_FULL_IDENTIFIER, "dev");
165+
assert_eq!(POLYGON_AMOY_FULL_IDENTIFIER, "polygon-amoy");
167166
assert_eq!(ETH_MAINNET_FULL_IDENTIFIER, "eth-mainnet");
168167
assert_eq!(ETH_ROPSTEN_FULL_IDENTIFIER, "eth-ropsten");
168+
assert_eq!(DEV_CHAIN_FULL_IDENTIFIER, "dev");
169169
assert_eq!(
170170
CLIENT_REQUEST_PAYLOAD_CURRENT_VERSION,
171171
DataVersion { major: 0, minor: 1 }

masq_lib/src/shared_schema.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use crate::constants::{
44
DEFAULT_GAS_PRICE, DEFAULT_UI_PORT, DEV_CHAIN_FULL_IDENTIFIER, ETH_MAINNET_FULL_IDENTIFIER,
55
ETH_ROPSTEN_FULL_IDENTIFIER, HIGHEST_USABLE_PORT, LOWEST_USABLE_INSECURE_PORT,
6-
POLYGON_MAINNET_FULL_IDENTIFIER, POLYGON_MUMBAI_FULL_IDENTIFIER,
6+
POLYGON_AMOY_FULL_IDENTIFIER, POLYGON_MAINNET_FULL_IDENTIFIER,
77
};
88
use crate::crash_point::CrashPoint;
99
use clap::{App, Arg};
@@ -64,7 +64,7 @@ pub const NEIGHBORS_HELP: &str = "One or more Node descriptors for running Nodes
6464
on startup. A Node descriptor looks similar to one of these:\n\n\
6565
masq://polygon-mainnet:[email protected]:9342\n\
6666
masq://eth-mainnet:[email protected]:5542\n\
67-
masq://polygon-mumbai:[email protected]:10504\n\
67+
masq://polygon-amoy:[email protected]:10504\n\
6868
masq://eth-ropsten:[email protected]:6642/4789/5254\n\n\
6969
Notice each of the different chain identifiers in the masq protocol prefix - they determine a family of chains \
7070
and also the network the descriptor belongs to (mainnet or a testnet). See also the last descriptor which shows \
@@ -256,7 +256,7 @@ pub fn official_chain_names() -> &'static [&'static str] {
256256
&[
257257
POLYGON_MAINNET_FULL_IDENTIFIER,
258258
ETH_MAINNET_FULL_IDENTIFIER,
259-
POLYGON_MUMBAI_FULL_IDENTIFIER,
259+
POLYGON_AMOY_FULL_IDENTIFIER,
260260
ETH_ROPSTEN_FULL_IDENTIFIER,
261261
DEV_CHAIN_FULL_IDENTIFIER,
262262
]
@@ -757,7 +757,7 @@ mod tests {
757757
on startup. A Node descriptor looks similar to one of these:\n\n\
758758
masq://polygon-mainnet:[email protected]:9342\n\
759759
masq://eth-mainnet:[email protected]:5542\n\
760-
masq://polygon-mumbai:[email protected]:10504\n\
760+
masq://polygon-amoy:[email protected]:10504\n\
761761
masq://eth-ropsten:[email protected]:6642/4789/5254\n\n\
762762
Notice each of the different chain identifiers in the masq protocol prefix - they determine a family of chains \
763763
and also the network the descriptor belongs to (mainnet or a testnet). See also the last descriptor which shows \
@@ -1144,7 +1144,7 @@ mod tests {
11441144
let mut iterator = official_chain_names().iter();
11451145
assert_eq!(Chain::from(*iterator.next().unwrap()), Chain::PolyMainnet);
11461146
assert_eq!(Chain::from(*iterator.next().unwrap()), Chain::EthMainnet);
1147-
assert_eq!(Chain::from(*iterator.next().unwrap()), Chain::PolyMumbai);
1147+
assert_eq!(Chain::from(*iterator.next().unwrap()), Chain::PolyAmoy);
11481148
assert_eq!(Chain::from(*iterator.next().unwrap()), Chain::EthRopsten);
11491149
assert_eq!(Chain::from(*iterator.next().unwrap()), Chain::Dev);
11501150
assert_eq!(iterator.next(), None)

masq_lib/src/test_utils/utils.rs

+10-2
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,16 @@ pub fn ensure_node_home_directory_exists(module: &str, name: &str) -> PathBuf {
3030
}
3131

3232
pub fn is_running_under_github_actions() -> bool {
33-
if let Ok(value) = std::env::var("GITHUB_ACTIONS") {
34-
&value == "true"
33+
is_env_variable_set("GITHUB_ACTIONS", "true")
34+
}
35+
36+
pub fn is_test_generated_data_allowed_to_escape_project_dir() -> bool {
37+
is_env_variable_set("ALLOW_TEST_DATA_ESCAPE_PROJECT_DIR", "true")
38+
}
39+
40+
fn is_env_variable_set(var_name: &str, searched_value: &str) -> bool {
41+
if let Ok(value) = std::env::var(var_name) {
42+
value == searched_value
3543
} else {
3644
false
3745
}

masq_lib/src/utils.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -49,14 +49,14 @@ fn compute_data_directory_help() -> String {
4949
let polygon_mainnet_dir = Path::new(&data_dir.to_str().unwrap())
5050
.join("MASQ")
5151
.join("polygon-mainnet");
52-
let polygon_mumbai_dir = Path::new(&data_dir.to_str().unwrap())
52+
let polygon_amoy_dir = Path::new(&data_dir.to_str().unwrap())
5353
.join("MASQ")
54-
.join("polygon-mumbai");
54+
.join("polygon-amoy");
5555
format!("Directory in which the Node will store its persistent state, including at least its database \
5656
and by default its configuration file as well. By default, your data-directory is located in \
5757
your application directory, under your home directory e.g.: '{}'.\n\n\
5858
In case you change your chain to a different one, the data-directory path is automatically changed \
59-
to end with the name of your chain: e.g.: if you choose polygon-mumbai, then data-directory is \
59+
to end with the name of your chain: e.g.: if you choose polygon-amoy, then data-directory is \
6060
automatically changed to: '{}'.\n\n\
6161
You can specify your own data-directory to the Daemon in two different ways: \n\n\
6262
1. If you provide a path without the chain name on the end, the Daemon will automatically change \
@@ -65,7 +65,7 @@ fn compute_data_directory_help() -> String {
6565
2. If you provide your data directory with the corresponding chain name on the end, eg: {}/masq_home/polygon-mainnet, \
6666
there will be no change until you set the chain parameter to a different value.",
6767
polygon_mainnet_dir.to_string_lossy().to_string().as_str(),
68-
polygon_mumbai_dir.to_string_lossy().to_string().as_str(),
68+
polygon_amoy_dir.to_string_lossy().to_string().as_str(),
6969
&home_dir.to_string_lossy().to_string().as_str(),
7070
&home_dir.to_string_lossy().to_string().as_str(),
7171
home_dir.to_string_lossy().to_string().as_str()

0 commit comments

Comments
 (0)