From 6948418865a80a6e900fca9eedb665430e310deb Mon Sep 17 00:00:00 2001 From: dgtlmoon Date: Sun, 9 Feb 2025 00:13:47 +0100 Subject: [PATCH] WIP --- changedetectionio/conditions.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/changedetectionio/conditions.py b/changedetectionio/conditions.py index 7a70874a0..9fc8742f0 100644 --- a/changedetectionio/conditions.py +++ b/changedetectionio/conditions.py @@ -15,8 +15,8 @@ operator_choices = [ ("contains_regex", "Text Matches Regex"), ("!contains_regex", "Text Does NOT Match Regex"), ("changed > minutes", "Changed more than X minutes ago"), - ("watch_uuid_unviewed_change", "Watch UUID had an unviewed change"), - ("watch_uuid_not_unviewed_change", "Watch UUID NOT had an unviewed change") +# ("watch_uuid_unviewed_change", "Watch UUID had an unviewed change"), #('if'? ) +# ("watch_uuid_not_unviewed_change", "Watch UUID NOT had an unviewed change") #('if'? ) # ("watch_uuid_changed", "Watch UUID had unviewed change"), # ("watch_uuid_not_changed", "Watch UUID did NOT have unviewed change"), # ("!!", "Is Truthy"), @@ -37,15 +37,13 @@ operator_choices = [ # Fields available in the rules field_choices = [ ("extracted_number", "Extracted Number"), - ("diff_removed", "Diff Removed"), - ("diff_added", "Diff Added"), - ("page_text", "Page Text"), - ("page_title", "Page Title"), + ("page_filtered_text", "Page text After Filters"), + ("page_title", "Page Title"), # actual page title ("watch_uuid", "Watch UUID"), ("watch_history_length", "History Length"), ("watch_history", "All Watch Text History"), ("watch_check_count", "Watch Check Count"), - ("watch_uuid", "Other Watch by UUID"), + ("watch_uuid", "Other Watch by UUID"), # (Maybe this is 'if' ??) #("requests_get", "Web GET requests (https://..)") ] @@ -95,5 +93,6 @@ def run(ruleset, data): try: return jsonLogic(ruleset, data, CUSTOM_OPERATIONS) except Exception as e: + # raise some custom nice handler print(f"❌ Error evaluating JSON Logic: {e}") return False