tsukinoinaba / MochiFeed

A local YouTube subscription feed on the CLI!
GNU General Public License v3.0
0 stars 0 forks source link

MochiFeed "forgets" when newest video for a channel is deleted #1

Open tsukinoinaba opened 2 months ago

tsukinoinaba commented 2 months ago

Cause

The memory file (latest_vids.txt) only stores the newest video's ID. If that video is later deleted or privated, the ID in the memory file will not match any of the videos in the RSS feed. Consequently, MochiFeed will fetch old videos that have appeared in a previous sync.

Consequences

This not only wastes time (doing 15 yt-dlp calls to get the video duration per channel affected), it also clogs up the list of videos with old videos and may cause confusion to the user.

When does it happen

This issue mainly happens when the newest video is a livestream, as livestreams often get deleted/privated after they end.

Proposed solution

The current idea is to store the second newest video as well in the memory file. This does not guarantee that this issue won't ever happen (e.g. both of the newest videos get deleted), but such cases should be a lot rarer. The amount of videos "remembered" can be further increased in the future if necessary.