def handle_noargs(self, **options): translation.activate(settings.LANGUAGE_CODE) logging.basicConfig(level=logging.DEBUG, format="%(message)s") logging.info("-" * 72) send_all() translation.deactivate()
def send_queued_notifications(*args): """ Sends queued notifications. settings.PINAX_NOTIFICATIONS_QUEUE_ALL needs to be true in order to take advantage of this. """ try: from notification.engine import send_all except ImportError: return # Make sure the application can write to the location where lock files are stored. if not args and getattr(settings, 'NOTIFICATION_LOCK_LOCATION', None): send_all(settings.NOTIFICATION_LOCK_LOCATION) else: send_all(*args)
def handle_noargs(self, **options): logging.basicConfig(level=logging.DEBUG, format="%(message)s") logging.info("-" * 72) send_all()
def emit_notices(): send_all()
def emit_notices(): """Don't fire this too often if using multiple celery workers - the send_all engine is not safe to use cross-machine, since the lock it uses is on a local disk. """ send_all()
def handle_noargs(self, **options): send_all()
def handle(self, *args, **options): # Franku: Uncomment for debugging purposes # logging.basicConfig(level=logging.DEBUG, format='%(message)s') logging.info('-' * 72) send_all()
def emit_notifications(): logger.info('notifications emitting') return send_all()
def emit_notices(): celery_logger.info("Emitting notices ...") send_all()
def handle(self, *args, **options): logging.basicConfig(level=logging.DEBUG, format="%(message)s") logging.info("-" * 72) send_all(workers=options['workers'], processes=options['processes'])