This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from celery.task import task | |
from imagekit.cachestate import PessimisticCacheStateBackend | |
@task | |
def generate(model, pk, attr): | |
try: | |
instance = model._default_manager.get(pk=pk) | |
except model.DoesNotExist: |