From 4ac03293ed8fe7b423d943f9eb12a27147758a1e Mon Sep 17 00:00:00 2001 From: Aiden McClelland Date: Fri, 29 Apr 2022 15:31:49 -0600 Subject: [PATCH] attempt to heal when health check passes --- backend/src/manager/health.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/src/manager/health.rs b/backend/src/manager/health.rs index b8dad0fae..81aa28627 100644 --- a/backend/src/manager/health.rs +++ b/backend/src/manager/health.rs @@ -5,7 +5,7 @@ use patch_db::{DbHandle, LockType}; use tracing::instrument; use crate::context::RpcContext; -use crate::dependencies::{break_transitive, DependencyError}; +use crate::dependencies::{break_transitive, heal_transitive, DependencyError}; use crate::s9pk::manifest::PackageId; use crate::status::health_check::{HealthCheckId, HealthCheckResult}; use crate::status::MainStatus; @@ -115,6 +115,8 @@ pub async fn check( &mut BTreeMap::new(), ) .await?; + } else { + heal_transitive(ctx, &mut tx, &dependent, id).await?; } }