mirror of
https://github.com/YGGverse/aquatic-crawler.git
synced 2026-03-31 17:15:35 +00:00
handle incomplete (updating) feed sources
This commit is contained in:
parent
8c37cab04e
commit
f4425557ee
2 changed files with 14 additions and 11 deletions
11
src/main.rs
11
src/main.rs
|
|
@ -89,7 +89,16 @@ async fn main() -> Result<()> {
|
|||
// * aquatic server may update the stats at this moment, handle result manually
|
||||
match api::infohashes(source) {
|
||||
Ok(infohashes) => {
|
||||
for i in infohashes {
|
||||
for i in match infohashes {
|
||||
Some(h) => h,
|
||||
None => {
|
||||
// skip without panic
|
||||
debug.error(&format!(
|
||||
"The feed `{source}` has an incomplete format (or is still updating); skip."
|
||||
));
|
||||
continue;
|
||||
}
|
||||
} {
|
||||
// is already indexed?
|
||||
if index.has(&i) {
|
||||
continue;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue