Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(3)  |  Call(2)  |  Derive(0)  |  Import(1)

src/d/j/django-cache-purge-hooks-0.3.0/cache_purge_hooks/shortcuts.py   django-cache-purge-hooks(Download)
from django.db.models.signals import post_save, post_delete, pre_delete, pre_save
from functools import partial
from cache_purge_hooks.manager import CacheManager
import logging
 
	except AttributeError:
		pass
	with CacheManager() as cm:
		for url in urls:
			logging.info("expire:", url)
def __post_delete_hook(model, func, instance, **kwargs):
	urls = instance.__cache_prehook_urls
	with CacheManager() as cm:
		for url in urls:
			logging.info("expire:", url)