Skip to content

Commit 596886a

Browse files
committed
fix: add miner_name
1 parent c561878 commit 596886a

File tree

1 file changed

+3
-12
lines changed

1 file changed

+3
-12
lines changed

cli/src/config.rs

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ pub struct TapeConfig {
1616

1717
#[derive(Debug, Serialize, Deserialize, Clone)]
1818
pub struct MiningConfig {
19+
pub miner_name: String,
1920
pub num_cores: usize,
2021
pub max_memory_mb: u64,
2122
pub max_poa_threads: u64,
@@ -209,6 +210,7 @@ impl Default for TapeConfig {
209210
fn default() -> Self {
210211
Self {
211212
mining: MiningConfig{
213+
miner_name: "tape_miner".to_string(),
212214
num_cores: num_cpus::get(),
213215
max_memory_mb: 16384,
214216
max_poa_threads: 4,
@@ -248,18 +250,7 @@ mod tests {
248250
fn test_toml_parsing_works_properly() {
249251
let toml_content = r#"
250252
[mining]
251-
num_cores = 4
252-
max_memory_mb = 16384
253-
max_poa_threads = 4
254-
max_pow_threads = 4
255-
256-
[performance]
257-
num_cores = 4
258-
max_memory_mb = 16384
259-
max_poa_threads = 4
260-
max_pow_threads = 4
261-
262-
[performance]
253+
miner_name = "tape_miner"
263254
num_cores = 4
264255
max_memory_mb = 16384
265256
max_poa_threads = 4

0 commit comments

Comments
 (0)