Private
Public Access
Stop retention from bringing deleted articles back (#29)
The nightly purge deleted articles, but a feed that still listed an entry would re-insert it on its next poll as a brand-new, unread article. For feeds with long archives, old items could reappear after every retention run. The purge now leaves a (feed, guid) tombstone per deleted article, and ingestion skips tombstoned guids. With retention on, entries whose own publish date is already outside the window are not ingested at all, so a long archive isn't fetched only to be purged and tombstoned the same night. Undated entries rely on the tombstone. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
73dbee9400
commit
f8cd1eb33e
6 files changed
+156
-5
No files matched your search
@@ -0,0 +1,27 @@
|
||||
# Generated by Django 5.2.18 on 2026-11-01 16:28
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('articles', '0004_starred_saved_as_system_tags'),
|
||||
('feeds', '0006_backfill_feed_next_fetch_at'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='PurgedArticle',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('guid', models.CharField(max_length=1000)),
|
||||
('purged_at', models.DateTimeField(auto_now_add=True)),
|
||||
('feed', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='purged_articles', to='feeds.feed')),
|
||||
],
|
||||
options={
|
||||
'unique_together': {('feed', 'guid')},
|
||||
},
|
||||
),
|
||||
]
|
||||
Reference in new issue
Block a user