mostrar error en url list

This commit is contained in:
Cat /dev/Nulo 2024-06-18 16:53:56 -03:00
parent 72282c71b8
commit c3b968cf12

View file

@ -329,13 +329,25 @@ impl Auto {
async fn download_supermercado(self, supermercado: Supermercado) -> anyhow::Result<()> {
{
let t0 = now_sec();
self.get_and_save_urls(&supermercado).await?;
match self.get_and_save_urls(&supermercado).await {
Ok(_) => {
self.inform(&format!(
"Downloaded url list {:?} (took {})",
&supermercado,
now_sec() - t0
))
.await;
.await
}
Err(err) => {
self.inform(&format!(
"[{:?}] FAILED url list: {:?} (took {})",
&supermercado,
err,
now_sec() - t0
))
.await
}
}
}
let links: Vec<String> = {
let mut links = self.db.get_urls_by_domain(supermercado.host()).await?;