fix deadlock on install (#2667)

* fix deadlock on install

* improve pruning script

* bump tokio
This commit is contained in:
Aiden McClelland
2024-07-11 14:55:13 -06:00
committed by GitHub
parent 87322744d4
commit 6def083b4f
20 changed files with 273 additions and 154 deletions

View File

@@ -374,9 +374,11 @@ impl Service {
entry.as_icon_mut().ser(&icon)?;
// TODO: marketplace url
// TODO: dependency info
Ok(())
})
.await?;
Ok(service)
}

View File

@@ -294,9 +294,12 @@ impl ServiceMap {
.into(),
);
}
drop(service);
sync_progress_task.await.map_err(|_| {
Error::new(eyre!("progress sync task panicked"), ErrorKind::Unknown)
})??;
Ok(())
})
.boxed())

View File

@@ -20,7 +20,6 @@ impl Handler<Restart> for ServiceActor {
.except::<DependencyConfig>()
}
async fn handle(&mut self, _: Guid, _: Restart, jobs: &BackgroundJobQueue) -> Self::Response {
dbg!("here");
// So Need a handle to just a single field in the state
let temp = TempDesiredRestore::new(&self.0.persistent_container.state);
let mut current = self.0.persistent_container.state.subscribe();
@@ -77,7 +76,6 @@ impl Handler<Restart> for ServiceActor {
impl Service {
#[instrument(skip_all)]
pub async fn restart(&self, id: Guid) -> Result<(), Error> {
dbg!("here");
self.actor.send(id, Restart).await
}
}