fix: 仅对需要重生成的日期联网补拉
This commit is contained in:
@ -302,13 +302,16 @@ def main():
|
||||
_, natural_week_end = week_bounds(current_week)
|
||||
day_start = max(daily_start, month_start, current_week)
|
||||
day_end = min(month_end, natural_week_end)
|
||||
if args.fetch_missing:
|
||||
for offset in range((day_end - day_start).days + 1):
|
||||
ensure_day_synced(day_start + timedelta(days=offset))
|
||||
|
||||
def has_messages_or_fetch(day: date) -> bool:
|
||||
if args.fetch_missing:
|
||||
ensure_day_synced(day)
|
||||
return has_messages(day)
|
||||
|
||||
for day in missing_message_dates(
|
||||
day_start,
|
||||
day_end,
|
||||
has_messages,
|
||||
has_messages_or_fetch,
|
||||
output_for_day,
|
||||
args.overwrite,
|
||||
refresh_tagged_from,
|
||||
|
||||
Reference in New Issue
Block a user