Remove the email pipeline
Test and publish / test (push) Successful in 1m59s
Test and publish / publish (push) Successful in 1m41s

The mailbox sync (Microsoft Graph and IMAP), its Claude classifier, the
/email routes and the Settings page's email section are taken out while
the pipeline is unused. The last commit with it is tagged
email-pipeline-last; reverting this commit brings it back.

The status rules the capture path shares (statusOrder, StatusAdvances,
NormalizeStatus) move to job_status.go with their tests. ProcessedEmail
stays in the migration, marked dormant, so its history survives for a
restored pipeline. golang.org/x/oauth2 is no longer needed.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-10-14 22:48:07 +01:00
co-authored by Claude Opus 5.5
parent 6b14a96261
commit b7021ca117
32 changed files with 199 additions and 2284 deletions
+25
View File
@@ -288,3 +288,28 @@ func TestTruncateRunes(t *testing.T) {
t.Fatalf("got %q", got)
}
}
func TestTruncate(t *testing.T) {
cases := []struct {
name string
s string
maxLen int
want string
}{
{"shorter than the cap is unchanged", "abc", 10, "abc"},
{"exactly at the cap is unchanged", "abcde", 5, "abcde"},
{"longer is cut to the cap", "abcdef", 3, "abc"},
{"zero cap yields the empty string", "abc", 0, ""},
{"empty input", "", 5, ""},
// Bytes, not runes: the cut can land mid-rune. Asserted so the
// behaviour is a documented choice rather than a lurking surprise.
{"multi-byte runes are cut by byte", "é", 1, "\xc3"},
}
for _, c := range cases {
t.Run(c.name, func(t *testing.T) {
if got := truncate(c.s, c.maxLen); got != c.want {
t.Fatalf("truncate(%q, %d) = %q, want %q", c.s, c.maxLen, got, c.want)
}
})
}
}