geopython / geopython/GeoHealthCheck

Streamline email functionality

Offen
#417 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
enhancement
Vorherrschende Sprache
Python
Sterne
92
Forks
75
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

**Is your feature request related to a problem? Please describe.**
Email is sent in two places: in `notifications.py` and in `util.py` (`send_email` function).
Via #416 some fixes were made in `notifications.py` to cope with various email configurations TLS, no Auth etc, for both Docker and regular installs. This is for Resource notification only. All other email (lost password, status summary, ..) is still sent
with `util.py-send_email`.

**Describe the solution you'd like**
Provide a single `send_email()` function for all email-sending cases. Best is to take `util.py-send_email` and extend with the implementation in `notifications.py`. Make the function robust for config errors. May still be lean/silently fail, on `login()` failure as that is optional and may break existing installs.

**Describe alternatives you've considered**
We could discard `SMTPLib` and use a higher level email lib. But that also introduces an additional dependency, plus may break existing installations.

**Additional context**
N.A.

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Lies die Funktion send_email in util.py und die E-Mail-Implementierung in notifications.py und verfolge anschließend ihre Aufrufer für Ressourcenbenachrichtigungen, E-Mails für verlorene Passwörter und Statuszusammenfassungen. Vergleiche das im Issue beschriebene Konfigurations- und Fehlerverhalten; abgeschlossen bedeutet, dass alle Fälle des E-Mail-Versands eine einzige robuste send_email-Funktion verwenden, ohne das optionale Login-Verhalten zu beeinträchtigen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
python
Bereich
backend
Issue-Typ
Feature
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
45/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.