django-codenerix-email 4.0.11__py2.py3-none-any.whl → 4.0.13__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- codenerix_email/__init__.py +1 -1
- codenerix_email/models.py +29 -6
- {django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/METADATA +1 -1
- {django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/RECORD +7 -7
- {django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/LICENSE +0 -0
- {django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/WHEEL +0 -0
- {django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/top_level.txt +0 -0
codenerix_email/__init__.py
CHANGED
codenerix_email/models.py
CHANGED
|
@@ -237,7 +237,12 @@ class EmailMessage(CodenerixModel, Debugger):
|
|
|
237
237
|
use_tls = settings.EMAIL_USE_TLS
|
|
238
238
|
|
|
239
239
|
# Remember last connection data
|
|
240
|
-
|
|
240
|
+
connect_info = {
|
|
241
|
+
"host": host,
|
|
242
|
+
"port": port,
|
|
243
|
+
"use_tls": use_tls,
|
|
244
|
+
"legacy": legacy,
|
|
245
|
+
}
|
|
241
246
|
# Get connection
|
|
242
247
|
return (
|
|
243
248
|
get_connection(
|
|
@@ -247,7 +252,7 @@ class EmailMessage(CodenerixModel, Debugger):
|
|
|
247
252
|
password=password,
|
|
248
253
|
use_tls=use_tls,
|
|
249
254
|
),
|
|
250
|
-
|
|
255
|
+
connect_info,
|
|
251
256
|
)
|
|
252
257
|
|
|
253
258
|
def connect(self, legacy=False):
|
|
@@ -310,7 +315,8 @@ class EmailMessage(CodenerixModel, Debugger):
|
|
|
310
315
|
ci.get("port", "-"),
|
|
311
316
|
ci.get("use_tls", "-"),
|
|
312
317
|
)
|
|
313
|
-
|
|
318
|
+
if not silent or debug:
|
|
319
|
+
self.warning(error)
|
|
314
320
|
if self.log is None:
|
|
315
321
|
self.log = ""
|
|
316
322
|
self.log += f"{error}\n"
|
|
@@ -359,19 +365,36 @@ class EmailMessage(CodenerixModel, Debugger):
|
|
|
359
365
|
break
|
|
360
366
|
except ssl.SSLError as e:
|
|
361
367
|
error = f"SSLError: {e}\n"
|
|
362
|
-
|
|
368
|
+
if not silent or debug:
|
|
369
|
+
self.warning(error)
|
|
363
370
|
if self.log is None:
|
|
364
371
|
self.log = ""
|
|
365
372
|
self.log += f"{error}\n"
|
|
366
373
|
except smtplib.SMTPServerDisconnected as e:
|
|
367
374
|
error = f"SMTPServerDisconnected: {e}\n"
|
|
368
|
-
|
|
375
|
+
if not silent or debug:
|
|
376
|
+
self.warning(error)
|
|
369
377
|
if self.log is None:
|
|
370
378
|
self.log = ""
|
|
371
379
|
self.log += f"{error}\n"
|
|
380
|
+
try:
|
|
381
|
+
connection.open()
|
|
382
|
+
error = None
|
|
383
|
+
except (
|
|
384
|
+
smtplib.SMTPAuthenticationError,
|
|
385
|
+
OSError,
|
|
386
|
+
TimeoutError,
|
|
387
|
+
) as e:
|
|
388
|
+
error = f"SMTPServerReconnect: {e}\n"
|
|
389
|
+
if not silent or debug:
|
|
390
|
+
self.warning(error)
|
|
391
|
+
if self.log is None:
|
|
392
|
+
self.log = ""
|
|
393
|
+
self.log += f"{error}\n"
|
|
372
394
|
except smtplib.SMTPException as e:
|
|
373
395
|
error = f"SMTPException: {e}\n"
|
|
374
|
-
|
|
396
|
+
if not silent or debug:
|
|
397
|
+
self.warning(error)
|
|
375
398
|
if self.log is None:
|
|
376
399
|
self.log = ""
|
|
377
400
|
self.log += f"{error}\n"
|
{django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/METADATA
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: django-codenerix-email
|
|
3
|
-
Version: 4.0.
|
|
3
|
+
Version: 4.0.13
|
|
4
4
|
Summary: Codenerix Email is a module that enables CODENERIX to set send emails in a general manner.
|
|
5
5
|
Home-page: https://github.com/codenerix/django-codenerix-email
|
|
6
6
|
Author: Juan Miguel Taboada Godoy <juanmi@juanmitaboada.com>, Juan Soler Ruiz <soleronline@gmail.com>
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
codenerix_email/__init__.py,sha256=
|
|
1
|
+
codenerix_email/__init__.py,sha256=aVCTNAdOJrmAaT21XJ3kR6V_FQX2uoJDgq21V0kyKR0,149
|
|
2
2
|
codenerix_email/admin.py,sha256=o3b-MaD7xsWeta0yfU9YNeKBmHQIcmHqXmP2t-hrrWc,1208
|
|
3
3
|
codenerix_email/apps.py,sha256=WXqu1XQibDDyCvvQYt2JbTK4GIpW8BNv5DCbRJS2mmk,149
|
|
4
4
|
codenerix_email/forms.py,sha256=n-UrVPI7NMXNImEdJ4uB0HWHEvBNv71YKZ_RPLW4FSg,4075
|
|
5
|
-
codenerix_email/models.py,sha256=
|
|
5
|
+
codenerix_email/models.py,sha256=HnnSJ0RuVRyXqrk3s5aFyex0GLiQUUIo5ogUjAE5oio,19315
|
|
6
6
|
codenerix_email/urls.py,sha256=QYrSJdhCp2PLrcfv_Y7X4OzxqQ0Q2-z7ObDPE-_WLdw,2595
|
|
7
7
|
codenerix_email/urls_frontend.py,sha256=DG5WS_fGQJC9sezNebPwG-E_WtUWy3Kwz4VUxh82xuc,873
|
|
8
8
|
codenerix_email/views.py,sha256=PyOWSAblRLzbYAzzTCZTR-VapKzf7-jpxnJ9TwX2t7Y,4790
|
|
@@ -70,8 +70,8 @@ codenerix_email/migrations/__pycache__/__init__.cpython-311.pyc,sha256=RbbUUEhcJ
|
|
|
70
70
|
codenerix_email/migrations/__pycache__/__init__.cpython-35.pyc,sha256=2g70xiMW6oJNkIpRM-0Dr5h7AUac-3xyCXPONxp9BBw,147
|
|
71
71
|
codenerix_email/migrations/__pycache__/__init__.cpython-39.pyc,sha256=qNj2NH0YvoWPnCKxkVZPsEFsbM05y7t1njMskNISdVQ,168
|
|
72
72
|
codenerix_email/static/codenerix_email/partials/emailmessages_rows.html,sha256=2KjE_YZ91OAFZuHteQeQ2r2vOBeZmwmnJQ4L-bH4B50,1735
|
|
73
|
-
django_codenerix_email-4.0.
|
|
74
|
-
django_codenerix_email-4.0.
|
|
75
|
-
django_codenerix_email-4.0.
|
|
76
|
-
django_codenerix_email-4.0.
|
|
77
|
-
django_codenerix_email-4.0.
|
|
73
|
+
django_codenerix_email-4.0.13.dist-info/LICENSE,sha256=IXMIpi75XsrJt1Sznt4EftT9c_4X0C9eqK4tHhH8H48,11339
|
|
74
|
+
django_codenerix_email-4.0.13.dist-info/METADATA,sha256=eX2aBAN7AEnb_G-T_00F3AZZYw4SIc2bRbUDFo8-4ps,2640
|
|
75
|
+
django_codenerix_email-4.0.13.dist-info/WHEEL,sha256=z9j0xAa_JmUKMpmz72K0ZGALSM_n-wQVmGbleXx2VHg,110
|
|
76
|
+
django_codenerix_email-4.0.13.dist-info/top_level.txt,sha256=lljSA0iKE_UBEM5gIrGQwioC_i8Jjnp-aR1LFElENgw,16
|
|
77
|
+
django_codenerix_email-4.0.13.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
{django_codenerix_email-4.0.11.dist-info → django_codenerix_email-4.0.13.dist-info}/top_level.txt
RENAMED
|
File without changes
|