Skip to content

Commit 59b791a

Browse files
authored
ci: test against MSRV and 1.87 (#857)
* pin rust versions in ci * apply clippy suggestion * kill python after benchmark
1 parent ace1cc9 commit 59b791a

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

.github/workflows/ci.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,8 @@ jobs:
1818
fail-fast: false
1919
matrix:
2020
rust:
21-
- stable
21+
- 1.87.0 # Stable release as of 2025-05-17
2222
- 1.70.0 # MSRV
23-
- nightly
2423

2524
steps:
2625
- uses: actions/checkout@v4

benches/benchmarks/external_process.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,19 @@ fn python_fibonacci(c: &mut Criterion) {
2323
.is_ok();
2424

2525
if has_python3 {
26-
let process = create_command()
26+
let mut process = create_command()
2727
.stdin(Stdio::piped())
2828
.stdout(Stdio::piped())
2929
.spawn()
3030
.expect("Unable to start python process");
3131

3232
let mut stdin = process
3333
.stdin
34+
.take()
3435
.expect("Unable to get stdin for child process");
3536
let stdout = process
3637
.stdout
38+
.take()
3739
.expect("Unable to get stdout for child process");
3840
let mut stdout = BufReader::new(stdout);
3941
c.bench_function("fibonacci-python", |b| {
@@ -51,6 +53,7 @@ fn python_fibonacci(c: &mut Criterion) {
5153
});
5254

5355
// Ensure that your child process terminates itself gracefully!
56+
process.kill().expect("Unable to kill child process");
5457
}
5558
}
5659

0 commit comments

Comments
 (0)