Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump rand to 0.9 #1686

Merged
merged 4 commits into from
Feb 5, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ pem = "3.0.1"
pin-project = "1.0.4"
proc-macro2 = "1.0.29"
quote = "1.0.10"
rand = "0.8.3"
rand = "0.9.0"
rustls = { version = "0.23.16", default-features = false }
rustls-pemfile = "2.0.0"
schemars = "0.8.6"
Expand Down
14 changes: 14 additions & 0 deletions deny.toml
Original file line number Diff line number Diff line change
Expand Up @@ -97,3 +97,17 @@ name = "thiserror-impl"
name = "security-framework"
[[bans.skip]]
name = "core-foundation"

# currently tungstenite hasn't upgraded rand to 0.9 yet, all these are related
[[bans.skip]]
name = "rand"
[[bans.skip]]
name = "rand_core"
[[bans.skip]]
name = "rand_chacha"
[[bans.skip]]
name = "getrandom"
[[bans.skip]]
name = "wasi"
[[bans.skip]]
name = "zerocopy"
6 changes: 3 additions & 3 deletions kube-runtime/src/reflector/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ mod tests {
use futures::{stream, StreamExt, TryStreamExt};
use k8s_openapi::{api::core::v1::ConfigMap, apimachinery::pkg::apis::meta::v1::ObjectMeta};
use rand::{
distributions::{Bernoulli, Uniform},
distr::{Bernoulli, Uniform},
Rng,
};
use std::collections::{BTreeMap, HashMap};
Expand Down Expand Up @@ -256,8 +256,8 @@ mod tests {

#[tokio::test]
async fn reflector_store_should_not_contain_duplicates() {
let mut rng = rand::thread_rng();
let item_dist = Uniform::new(0_u8, 100);
let mut rng = rand::rng();
let item_dist = Uniform::new(0_u8, 100).unwrap();
let deleted_dist = Bernoulli::new(0.40).unwrap();
let store_w = store::Writer::default();
let store = store_w.as_reader();
Expand Down