Skip to content

Commit 085ee29

Browse files
GuillaumeGomezsyphar
authored andcommittedMar 17, 2025·
Remove humantime dependency
1 parent 0e7f0ec commit 085ee29

File tree

3 files changed

+5
-13
lines changed

3 files changed

+5
-13
lines changed
 

‎Cargo.lock

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

‎Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ chrono = { version = "0.4.11", default-features = false, features = ["clock", "s
9898

9999
# Transitive dependencies we don't use directly but need to have specific versions of
100100
thread_local = "1.1.3"
101-
humantime = "2.1.0"
102101
constant_time_eq = "0.3.0"
103102

104103
[target.'cfg(target_os = "linux")'.dependencies]

‎src/bin/cratesfyi.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ use docs_rs::{
2020
start_background_metrics_webserver, start_web_server,
2121
};
2222
use futures_util::StreamExt;
23-
use humantime::Duration;
2423
use once_cell::sync::OnceCell;
2524
use sentry::{
2625
TransactionContext, integrations::panic as sentry_panic,
@@ -712,7 +711,7 @@ enum LimitsSubcommand {
712711
#[arg(long)]
713712
targets: Option<usize>,
714713
#[arg(long)]
715-
timeout: Option<Duration>,
714+
timeout: Option<usize>,
716715
},
717716

718717
/// Remove sandbox limits overrides for a crate
@@ -748,7 +747,8 @@ impl LimitsSubcommand {
748747
let overrides = Overrides {
749748
memory,
750749
targets,
751-
timeout: timeout.map(Into::into),
750+
timeout: timeout
751+
.map(|timeout| std::time::Duration::from_secs(timeout as _)),
752752
};
753753
Overrides::save(&mut conn, &crate_name, overrides).await?;
754754
let overrides = Overrides::for_crate(&mut conn, &crate_name).await?;

0 commit comments

Comments
 (0)
Please sign in to comment.