global: snapshot

This commit is contained in:
nym21
2025-12-19 15:25:48 +01:00
parent 7c86c803fa
commit 03b83846ef
87 changed files with 2851 additions and 470 deletions

View File

@@ -64,7 +64,10 @@ impl<T: PriceSource> TrackedSource<T> {
}
/// Try to fetch, tracking health state
fn try_fetch<R>(&mut self, fetch: impl FnOnce(&mut T) -> Option<Result<R>>) -> Option<Result<R>> {
fn try_fetch<R>(
&mut self,
fetch: impl FnOnce(&mut T) -> Option<Result<R>>,
) -> Option<Result<R>> {
if !self.is_healthy() {
return Some(Err(Error::FetchFailed(format!(
"{} temporarily disabled (recheck in {}s)",