diff --git a/papi/main.py b/papi/main.py index 07036c0..dd04deb 100644 --- a/papi/main.py +++ b/papi/main.py @@ -278,9 +278,15 @@ def post_sonde_data( html = res.body.decode("utf-8") from papi.mail_sendermodel import sendmail - cond = False - if cond: - sendmail(html) + conf = PROBES[idsonde] + sumup = utils.sample2statuscount(present) + subject = " ; ".join(sumup) + sendmail( + htmlpart=html, + emails=conf["emails"], + subject=subject, + ) + return { "count": len(mesures_) if "date" in mesures_[0].content.keys()