Commit Graph
9 Commits
Author SHA1 Message Date
duffyduckandClaude Opus 5.5 d189424ab3 show time of last match, parse server timestamps as UTC
The match column now shows "27 · 22.09. 12:00", with the full date and
time in the tooltip. Server timestamps are naive UTC; appending 'Z'
before parsing keeps the browser from treating them as local time,
which also fixes mail dates in the rule test results.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 10:09:09 +02:00
duffyduckandClaude Opus 5.5 86ae896ae9 compact filter list: one row per rule, smaller global type scale
Pico scales the root font up to 125% on wide screens, which made the
whole admin UI oversized. Pin it to 93.75% and tighten spacing tokens.

The filter list is now a dense table-like list: switch, priority, name,
condition chips, target folder, match stats and icon buttons on a single
row (~35 rules fit on one screen instead of ~4). Warnings collapse into
a ⚠ icon with tooltip; attachment and date conditions render as short
chips; the full condition list is in the row tooltip; double-click opens
the rule. Account picker, summary and main actions share one header row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 09:56:32 +02:00
duffyduckandClaude Opus 5.5 1b4f6ed34e redesign filter page: rule test, match stats, warnings, toggle
- Rule tester (POST /api/filters/test): evaluates an unsaved rule
  read-only against the newest matching mails in the source folder,
  using an IMAP SEARCH on the first text condition to narrow candidates.
  Shows matches, near misses with the failing condition, and whether
  any candidate had an attachment at all (would have caught the
  Klarmobil and it-moench misconfigurations immediately).
- Per-rule match_count / last_match_at (new migration), incremented by
  the scheduler on every match and shown in the list.
- PATCH /api/filters/{id}/enabled toggles a rule without resetting its
  processed state (a full PUT re-evaluates every mail for that rule).
- New filter list: cards with enable switch, priority, condition and
  action chips, match stats, and warnings (display name in from/to,
  "am (exakt)" date, duplicates, empty values, invalid regex, move
  without folder). Quick filters for active/inactive/warnings/never
  matched; copy-as-template; remembered account selection.
- Edit dialog: wider layout, live warnings, integrated test panel,
  sensible defaults for new rules (from + date after Jan 1 + move).
- Light global refresh: nav with active item, page background, cards.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 09:48:12 +02:00
duffyduckandClaude Opus 4.7 9888a5749e raise imaplib._MAXLINE + broaden filter search
Live poll had been silently dying every 30s with
  "Fehler beim Abrufen von Ordner 'INBOX' — got more than 1000000 bytes"
Root cause: Python's imaplib hard-caps a single response at 1 MB. With
~150k UIDs in INBOX, "UID SEARCH ALL" returns a longer line than that,
imaplib throws, get_all_uids() returns [], the poll reports "0 Mail(s)
im Ordner, 0 Treffer" and nothing gets sorted. Bump _MAXLINE to 100 MB
(covers mailboxes with millions of mails).

Filter search haystack now also includes the German condition/action
labels ("am (exakt)", "ab / nach", "verschieben in Ordner", …) and a
"stop" token, so the user can spot mis-typed date rules by typing
"am" and see any on_date rules rather than having to know the
internal enum names.

Also audited every rule via SSH: no on_date/date-exact rules exist —
all 32 rules use `date after '2026-01-01'` correctly. cps datensysteme
still has its known duplicate conditions (harmless).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-09-17 18:59:19 +02:00
duffyduckandClaude Opus 4.7 1c30bffb5e add "reset all processed" button + endpoint
POST /api/filters/reset-all-processed drops and recreates the
processed_mails table — sekundenschnell auch bei Millionen Zeilen
via DROP+CREATE (same pattern as the fast clear-logs). Safe because
already-moved mails are no longer in the source folder, so a fresh
re-evaluation cannot re-move them, only pick up ones that were
skipped due to a rule bug (e.g. the has_attachment fix).

Button "Alle Regeln zurücksetzen" next to "Neue Regel" on the filter
list, with a confirmation dialog and result feedback.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-09-01 12:39:03 +02:00
duffyduckandClaude Opus 4.7 e4669cfccd add live search to filter rules list
Substring search across rule name, source folder, condition values
and action parameters. Filters the table client-side as the user
types and shows a match counter (e.g. "3 / 12").

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-31 10:51:32 +02:00
duffyduckandClaude Opus 4.7 202920b9ef auto-assign filter priority (max+10) on create
New filter rules no longer default to priority 100. Server picks
max(priority)+10 per account when client sends priority=None (or 10
if the account has no rules yet), and the UI pre-fills the input
with the next value instead of a fixed 100. Avoids ambiguous ordering
when multiple rules end up with the same priority.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-31 10:46:52 +02:00
duffyduck d148248682 addes folder backup attachments logging 2026-03-19 15:31:36 +01:00
Stefan Hacker 61c4384111 Initial commit: IMAP Mail Filter Service 2026-03-19 13:02:44 +01:00