[package] description = "Make retry like a built-in feature provided by Rust." documentation = "https://docs.rs/backon" name = "backon" readme = "../README.md" rust-version = "1.70" version = "1.3.0" edition.workspace = true license.workspace = true repository.workspace = true [package.metadata.docs.rs] all-features = true targets = [ "x86_64-unknown-linux-gnu", "x86_64-apple-darwin", "x86_64-pc-windows-msvc", "wasm32-unknown-unknown", ] [features] default = ["std-blocking-sleep", "tokio-sleep", "gloo-timers-sleep"] std-blocking-sleep = [] gloo-timers-sleep = ["dep:gloo-timers", "gloo-timers?/futures"] tokio-sleep = ["dep:tokio", "tokio?/time"] [dependencies] fastrand = "2" [target.'cfg(not(target_arch = "wasm32"))'.dependencies] tokio = { version = "1", optional = true } [target.'cfg(target_arch = "wasm32")'.dependencies] gloo-timers = { version = "0.3", optional = true } [dev-dependencies] anyhow = "1" reqwest = "0.12" spin = "0.9.8" [target.'cfg(target_arch = "wasm32")'.dev-dependencies] tokio = { version = "1", features = [ "macros", "rt", "sync", ], default-features = false } wasm-bindgen-test = "0.3" [target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies] sqlx = { version = "0.8.0", features = ["runtime-tokio", "sqlite"] } tokio = { version = "1", features = [ "time", "rt", "macros", "sync", "rt-multi-thread", ] }