Now imports the session type_code data

This commit is contained in:
Scott Idem
2024-05-07 10:21:07 -04:00
parent da86206a24
commit de822fb1ba
2 changed files with 19 additions and 0 deletions

View File

@@ -594,7 +594,19 @@ def send_email(
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.info('SMTP configuration, connect, and send')
log.setLevel(logging.DEBUG)
log.info(settings.SMTP['server'])
log.info(settings.SMTP['port'])
log.info(settings.SMTP['username'])
log.info(settings.SMTP['password'])
if test:
log.setLevel(logging.DEBUG)
log.info('[TEST] Test mode enabled')
log.info(settings.SMTP['server'])
log.info(settings.SMTP['port'])
log.info(settings.SMTP['username'])
log.info(settings.SMTP['password'])
try:
with smtplib.SMTP_SSL(settings.SMTP['server'], settings.SMTP['port'], context=context) as server:
log.debug('[TEST] SMTP log in...')