You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi everybody,
it's more a question not an issue. Please, tell me how to configure mail notifications in django-pyas2 if messege's STATUS is changed to ERROR. I've already tried to set EMAIL_HOST, etc. in my settings.py, but it doesn't work in this version. I found that in pyas2 was a bit of code which done this job, but here I'm afraid it disappeared.
Below the code from pyas2 about an email (maybe I'm wrong...)
# Build and send the AS2 message
try:
payload = as2lib.build_message(message)
as2lib.send_message(message, payload)
except Exception:
message.status = 'E'
txt = traceback.format_exc(None).decode('utf-8', 'ignore')
message.adv_status = \
_(u'Failed to send message, error:\n%(txt)s') % {'txt': txt}
pyas2init.logger.error(message.adv_status)
models.Log.objects.create(
message=message, status='E', text=message.adv_status)
message.save()
# Send mail here
as2utils.senderrorreport(message, message.adv_status)
sys.exit(2)
The text was updated successfully, but these errors were encountered:
Hi everybody,
it's more a question not an issue. Please, tell me how to configure mail notifications in django-pyas2 if messege's STATUS is changed to ERROR. I've already tried to set EMAIL_HOST, etc. in my settings.py, but it doesn't work in this version. I found that in pyas2 was a bit of code which done this job, but here I'm afraid it disappeared.
Below the code from pyas2 about an email (maybe I'm wrong...)
The text was updated successfully, but these errors were encountered: