Skip to content

Commit fbe2450

Browse files
refactor: move EXEC_HARNESS_VERSION and EXEC_HARNESS_COMMAND to orchestrator mod
1 parent ed7f77d commit fbe2450

5 files changed

Lines changed: 8 additions & 8 deletions

File tree

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ After releasing `memtrack` or `exec-harness`, you **must** update the version re
4141
const MEMTRACK_CODSPEED_VERSION: &str = "X.Y.Z"; // Update to new version
4242
```
4343

44-
2. **For exec-harness**: Update `EXEC_HARNESS_VERSION` in `src/exec/mod.rs`:
44+
2. **For exec-harness**: Update `EXEC_HARNESS_VERSION` in `src/executor/orchestrator.rs`:
4545
```rust
4646
const EXEC_HARNESS_VERSION: &str = "X.Y.Z"; // Update to new version
4747
```
@@ -57,7 +57,7 @@ The main runner (`codspeed-runner`) should be released after ensuring all depend
5757
**Verify binary version references**: Check that version constants in the runner code match the released versions:
5858

5959
- `MEMTRACK_CODSPEED_VERSION` in `src/executor/memory/executor.rs`
60-
- `EXEC_HARNESS_VERSION` in `src/exec/mod.rs`
60+
- `EXEC_HARNESS_VERSION` in `src/executor/orchestrator.rs`
6161

6262
#### Release Command
6363

src/cli/exec/mod.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,6 @@ pub mod multi_targets;
1818
/// We temporarily force this name for all exec runs
1919
pub const DEFAULT_REPOSITORY_NAME: &str = "local-runs";
2020

21-
pub const EXEC_HARNESS_COMMAND: &str = "exec-harness";
22-
pub const EXEC_HARNESS_VERSION: &str = "1.2.0";
23-
2421
#[derive(Args, Debug)]
2522
pub struct ExecArgs {
2623
#[command(flatten)]

src/cli/exec/multi_targets.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
use super::EXEC_HARNESS_COMMAND;
21
use crate::executor::config::BenchmarkTarget;
2+
use crate::executor::orchestrator::EXEC_HARNESS_COMMAND;
33
use crate::prelude::*;
44
use crate::project_config::{Target, TargetCommand, WalltimeOptions};
55
use exec_harness::BenchmarkCommand;

src/executor/orchestrator.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use super::{ExecutionContext, ExecutorName, get_executor_from_mode, run_executor};
22
use crate::api_client::CodSpeedAPIClient;
33
use crate::binary_installer::ensure_binary_installed;
4-
use crate::cli::exec::{EXEC_HARNESS_COMMAND, EXEC_HARNESS_VERSION, multi_targets};
4+
use crate::cli::exec::multi_targets;
55
use crate::cli::run::logger::Logger;
66
use crate::config::CodSpeedConfig;
77
use crate::executor::config::BenchmarkTarget;
@@ -17,6 +17,9 @@ use serde_json::Value;
1717
use std::collections::BTreeMap;
1818
use std::path::{Path, PathBuf};
1919

20+
pub const EXEC_HARNESS_COMMAND: &str = "exec-harness";
21+
pub const EXEC_HARNESS_VERSION: &str = "1.2.0";
22+
2023
/// Shared orchestration state created once per CLI invocation.
2124
///
2225
/// Holds the run-level configuration, environment provider, system info, and logger.

src/executor/tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,7 @@ fi
341341
command: &[String],
342342
) -> String {
343343
shell_words::join(
344-
std::iter::once(crate::cli::exec::EXEC_HARNESS_COMMAND)
344+
std::iter::once(crate::executor::orchestrator::EXEC_HARNESS_COMMAND)
345345
.chain(walltime_args.to_cli_args().iter().map(|s| s.as_str()))
346346
.chain(command.iter().map(|s| s.as_str())),
347347
)

0 commit comments

Comments
 (0)