Revert "comment out theme-checksum migration"

This reverts commit 2145b97d44.
This commit is contained in:
Chris Van 2013-06-06 14:47:22 -07:00
Родитель 2145b97d44
Коммит 3b7a2d2729
1 изменённых файлов: 8 добавлений и 8 удалений

Просмотреть файл

@ -1,12 +1,12 @@
#!/usr/bin/env python
# from addons.models import Persona
# from addons.tasks import calc_checksum
# from amo.utils import chunked
from addons.models import Persona
from addons.tasks import calc_checksum
from amo.utils import chunked
# def run():
# """Calculate checksums for all themes."""
# pks = Persona.objects.filter(checksum='').values_list('id', flat=True)
# for chunk in chunked(pks, 1000):
# [calc_checksum.delay(pk) for pk in chunk]
def run():
"""Calculate checksums for all themes."""
pks = Persona.objects.filter(checksum='').values_list('id', flat=True)
for chunk in chunked(pks, 1000):
[calc_checksum.delay(pk) for pk in chunk]