Document rule system
This commit is contained in:
@@ -6,7 +6,7 @@ from django.core.management.base import BaseCommand
|
||||
|
||||
from core.db.storage import db
|
||||
from core.lib.parsing import QueryError
|
||||
from core.lib.rules import NotificationRuleData
|
||||
from core.lib.rules import NotificationRuleData, RuleParseError
|
||||
from core.models import NotificationRule
|
||||
from core.util import logs
|
||||
|
||||
@@ -31,6 +31,8 @@ async def job(interval_seconds):
|
||||
# results = await db.schedule_query_results(rule.user, rule)
|
||||
except QueryError as e:
|
||||
log.error(f"Error running rule {rule}: {e}")
|
||||
except RuleParseError as e:
|
||||
log.error(f"Error parsing rule {rule}: {e}")
|
||||
|
||||
|
||||
class Command(BaseCommand):
|
||||
|
||||
Reference in New Issue
Block a user