Skip to content

Commit 19c517b

Browse files
authored
Bump rand from 0.8.5 to 0.9.0 (#77)
rand 0.9.0 renames a few things.
2 parents 589b8f3 + c8c12df commit 19c517b

File tree

3 files changed

+94
-17
lines changed

3 files changed

+94
-17
lines changed

Cargo.lock

+90-9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gitlab-runner/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ tracing = "0.1.40"
3232
doc-comment = "0.3.3"
3333
sha2 = "0.10.8"
3434
hmac = "0.12.1"
35-
rand = "0.8.5"
35+
rand = "0.9.0"
3636
tokio-util = { version = "0.7.10", features = [ "io" ] }
3737

3838
[dev-dependencies]

gitlab-runner/src/lib.rs

+3-7
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ use hmac::Mac;
1313
use job::{Job, JobLog};
1414
pub mod uploader;
1515
pub use logging::GitlabLayer;
16-
use rand::distributions::Alphanumeric;
17-
use rand::distributions::DistString;
16+
use rand::distr::Alphanumeric;
17+
use rand::distr::SampleString;
1818
use runlist::JobRunList;
1919
use tokio::fs::File;
2020
use tokio::io::AsyncReadExt;
@@ -351,11 +351,7 @@ impl RunnerBuilder {
351351
system_id
352352
} else {
353353
let mut system_id = String::from("r_");
354-
Alphanumeric.append_string(
355-
&mut rand::thread_rng(),
356-
&mut system_id,
357-
Self::DEFAULT_ID_LEN,
358-
);
354+
Alphanumeric.append_string(&mut rand::rng(), &mut system_id, Self::DEFAULT_ID_LEN);
359355
system_id
360356
}
361357
}

0 commit comments

Comments
 (0)