ecodev-core 0.0.27__py3-none-any.whl → 0.0.29__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.

Potentially problematic release.


This version of ecodev-core might be problematic. Click here for more details.

@@ -7,7 +7,6 @@ from email.mime.text import MIMEText
7
7
  from pathlib import Path
8
8
  from smtplib import SMTP
9
9
  from ssl import create_default_context
10
- from typing import Dict
11
10
 
12
11
  from pydantic_settings import BaseSettings
13
12
  from pydantic_settings import SettingsConfigDict
@@ -26,7 +25,7 @@ class EmailAuth(BaseSettings):
26
25
  EMAIL_AUTH = EmailAuth()
27
26
 
28
27
 
29
- def send_email(email: str, body: str, topic: str, images: Dict[str, Path]) -> None:
28
+ def send_email(email: str, body: str, topic: str, images: dict[str, Path] | None = None) -> None:
30
29
  """
31
30
  Generic email sender.
32
31
 
@@ -41,7 +40,7 @@ def send_email(email: str, body: str, topic: str, images: Dict[str, Path]) -> No
41
40
  em['To'] = email
42
41
  em['Subject'] = topic
43
42
  em.attach(MIMEText(body, 'html'))
44
- for tag, img_path in images.items():
43
+ for tag, img_path in (images or {}).items():
45
44
  with open(img_path, 'rb') as fp:
46
45
  img = MIMEImage(fp.read())
47
46
  img.add_header('Content-ID', f'<{tag}>')
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ecodev-core
3
- Version: 0.0.27
3
+ Version: 0.0.29
4
4
  Summary: Low level sqlmodel/fastapi/pydantic building blocks
5
5
  License: MIT
6
6
  Author: Thomas Epelbaum
@@ -45,6 +45,7 @@ Requires-Dist: pydantic-settings (>=2,<3)
45
45
  Requires-Dist: python-jose[cryptography] (>=3,<4)
46
46
  Requires-Dist: sqladmin (==0.15.2)
47
47
  Requires-Dist: sqlmodel (>=0,<1)
48
+ Requires-Dist: xlsxwriter (>=3,<4)
48
49
  Description-Content-Type: text/markdown
49
50
 
50
51
  # ecodev-core
@@ -11,7 +11,7 @@ ecodev_core/db_connection.py,sha256=qRcs0MjLFfhO7pnSof1l1m1BbPqYfEsUlMQkKT9fn_4,
11
11
  ecodev_core/db_filters.py,sha256=T_5JVF27UEu7sC6NOm7-W3_Y0GLfbWQO_EeTXcD2cv8,5041
12
12
  ecodev_core/db_insertion.py,sha256=RSCyAlUObbBlWJuMRX-YFY4VgtWqYLdwRqMWw--x95Y,3646
13
13
  ecodev_core/db_retrieval.py,sha256=IxyF3ZtKgACLiNFggK7boKggvMRKYDRD2IimxU4dap4,7345
14
- ecodev_core/email_sender.py,sha256=eoRhaltPnuogNt89G8I2GKEvFk0CNIDQPoDeWZ4Uo9Y,1612
14
+ ecodev_core/email_sender.py,sha256=XD7jAVXhGzvbiHqMhK9_aTEIS70Lw_CmPeAxRZGji-Y,1610
15
15
  ecodev_core/enum_utils.py,sha256=BkQ4YQ97tXBYmMcQiSIi0mbioD5CgVU79myg1BBAXuA,556
16
16
  ecodev_core/list_utils.py,sha256=Vyws12Jv0CLdQiQl1ym0z7E6-LJTLholYHZySQxYwhM,3006
17
17
  ecodev_core/logger.py,sha256=AWGGNZz12Ql0JDq1wCJQxwxK2syiczEBftmuJkjbAPw,3149
@@ -20,7 +20,7 @@ ecodev_core/permissions.py,sha256=WAx-ilMu8LlQp2sjJVdkhNQieytEaEm8577ZF1HWeTY,50
20
20
  ecodev_core/pydantic_utils.py,sha256=e3GH50JmcpTmd2UgrB94QSwWOlOCW3WIlVdyX9C4T-U,741
21
21
  ecodev_core/read_write.py,sha256=auJ5bBJTVGkLRkiP_vZxVCX64B0Y-9qpsaDhovHmbas,996
22
22
  ecodev_core/safe_utils.py,sha256=JCfxo6fcznjsL-XHNJ1TKo1UvfJB83WT5jpTFmtJwsE,6160
23
- ecodev_core-0.0.27.dist-info/LICENSE.md,sha256=jebQDe1ib9LAODuNvcSoo2CoqS6P0_q8--mMTICh_kI,1074
24
- ecodev_core-0.0.27.dist-info/METADATA,sha256=q3nWLxBLM5c9Iagi5n07Z-bYd1vNsig9T8rKLmNOfL4,3276
25
- ecodev_core-0.0.27.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
26
- ecodev_core-0.0.27.dist-info/RECORD,,
23
+ ecodev_core-0.0.29.dist-info/LICENSE.md,sha256=jebQDe1ib9LAODuNvcSoo2CoqS6P0_q8--mMTICh_kI,1074
24
+ ecodev_core-0.0.29.dist-info/METADATA,sha256=ixhS45ZEBips9qHEXN-RRRzCzJvAkiHigPV79-NotUo,3311
25
+ ecodev_core-0.0.29.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
26
+ ecodev_core-0.0.29.dist-info/RECORD,,