fix ABID generation consistency when self._state.adding is True

This commit is contained in:
Nick Sweeting 2024-08-20 05:56:19 -07:00
parent 9d2116ad9a
commit 4ae186dfca
No known key found for this signature in database
4 changed files with 91 additions and 33 deletions
archivebox/core

View file

@ -372,7 +372,7 @@ class ArchiveResult(ABIDModel):
abid_ts_src = 'self.snapshot.added'
abid_uri_src = 'self.snapshot.url'
abid_subtype_src = 'self.extractor'
abid_rand_src = 'self.id'
abid_rand_src = 'self.old_id'
EXTRACTOR_CHOICES = EXTRACTOR_CHOICES
old_id = models.BigIntegerField(default=rand_int_id, serialize=False, verbose_name='Old ID')