this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

count missing shards as zero size (#680)

authored by

Whyrusleeping and committed by
GitHub
9815da96 c168ade4

+4
+4
carstore/bs.go
··· 1278 1278 func shardSize(sh *CarShard) (int64, error) { 1279 1279 st, err := os.Stat(sh.Path) 1280 1280 if err != nil { 1281 + if os.IsNotExist(err) { 1282 + log.Warnw("missing shard, return size of zero", "path", sh.Path, "shard", sh.ID) 1283 + return 0, nil 1284 + } 1281 1285 return 0, fmt.Errorf("stat %q: %w", sh.Path, err) 1282 1286 } 1283 1287