python-general-be-lib 0.8.3__py3-none-any.whl → 0.8.4__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.
@@ -6,7 +6,7 @@ import math
6
6
  from functools import lru_cache
7
7
  from typing import Any, Type, Sequence, Iterable, Optional, Mapping
8
8
 
9
- from pydantic import BaseModel, TypeAdapter
9
+ from pydantic import BaseModel, TypeAdapter, ConfigDict
10
10
  from sqlalchemy import select, delete, update, insert, tuple_, Row, RowMapping, ColumnElement, Select, Insert, Update, Delete, func, ARRAY
11
11
  from sqlalchemy.engine.base import Engine
12
12
  from sqlalchemy.exc import DataError, IntegrityError, NoResultFound, OperationalError
@@ -46,11 +46,7 @@ def _reduced_model(entity: Type[Base], columns: frozenset[str]) -> Type[BaseMode
46
46
  # configurazione dei mapper (a differenza di ``column_attrs``/``attrs``).
47
47
  ordinate = [name for name in inspect(entity).columns.keys() if name in columns]
48
48
  digest = hashlib.sha1("|".join(ordinate).encode()).hexdigest()[:8]
49
- return entity.to_pydantic(
50
- model_name=f"{entity.__name__}_{digest}",
51
- full_optional=True,
52
- include_only=ordinate,
53
- )
49
+ return entity.to_pydantic(model_name=f"{entity.__name__}_{digest}", full_optional=True, include_only=ordinate, __config__=ConfigDict(arbitrary_types_allowed=True))
54
50
 
55
51
 
56
52
  class CrudRepository[Entity: Base | Type[Base]]:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-general-be-lib
3
- Version: 0.8.3
3
+ Version: 0.8.4
4
4
  Summary: General purpose backend library — SQLAlchemy CRUD/Geometry repositories, FastAPI exceptions, Pydantic base models, logger utilities.
5
5
  Author-email: Andrea Di Placido <a.diplacido@arpes.it>, "Arpes S.r.l." <it.admin@arpes.it>
6
6
  License: MIT
@@ -13,7 +13,7 @@ general/interface/metadata/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
13
13
  general/interface/metadata/crud_metadata.py,sha256=BFohkkpUd7w211NYqAD20X4ZpovrXH7BERA1_Rs4Dv0,23291
14
14
  general/interface/metadata/geom_metadata.py,sha256=J5SMXMiDUXnzt7bNH12LIQO6S7jcLNf7Cm4CdLXv8Lg,12255
15
15
  general/interface/repository/__init__.py,sha256=EcRukwf61Ua-9-JfM_ingVv1wXNRV8HBrrWwjj8m23w,136
16
- general/interface/repository/crud_repository.py,sha256=AdnI5nFb0G0V4eTIjXALTVvJ5aiV50xpI0pIh1S9S2w,39740
16
+ general/interface/repository/crud_repository.py,sha256=pvJ3UjIyyjO609D5J336ekbIV1d4ODat5Gi3pS73NI8,39774
17
17
  general/interface/repository/geometry_repository.py,sha256=WUnYOr0YOKNt7_lBa5HlbkGAkYuAaSrXqK7i0BQOctw,12101
18
18
  general/interface/repository/many_to_many_repository.py,sha256=ZyuK2fk5ZI9xE8xhZwk5Vb1QItnOxwEF5CGsemnMdn8,9197
19
19
  general/interface/repository/view_repository.py,sha256=ZqekhnSvHH_CJFb546tjUwnwGbwzyxZMx-f7yUvOl50,6206
@@ -25,8 +25,8 @@ general/interface/repository/handler/json_handler.py,sha256=XNAgIkUGQX8ttTsqtqE8
25
25
  general/interface/repository/handler/json_ilike_handler.py,sha256=NXqcS1YOtcOStdl7sp2cYqFMkEdcxoVmaNJewJEzL3M,4738
26
26
  general/interface/repository/handler/or_handler.py,sha256=hZ4Nc-nTi7Nh-krPUIlyCEg3q6H0D96T_oMVAzxezKY,4839
27
27
  general/interface/repository/handler/statement_manager.py,sha256=yCMR1vNnXYmmY4HwI2CDZLI513GzyVZniN31QJFGKKA,7080
28
- python_general_be_lib-0.8.3.dist-info/licenses/LICENSE,sha256=iUaO1XZyB9P3Tmog0OILuTisP6vXGe3QKz-4yRTxOFk,1069
29
- python_general_be_lib-0.8.3.dist-info/METADATA,sha256=Kjj0vny9_DD5ICWvqKD2NLUl7b6n3p-lkn7_g8ixYIw,2962
30
- python_general_be_lib-0.8.3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
31
- python_general_be_lib-0.8.3.dist-info/top_level.txt,sha256=tTZePW8_CNUqSgKFd2SEH72ZbnhS0OYjRsgcv0ikSFY,8
32
- python_general_be_lib-0.8.3.dist-info/RECORD,,
28
+ python_general_be_lib-0.8.4.dist-info/licenses/LICENSE,sha256=iUaO1XZyB9P3Tmog0OILuTisP6vXGe3QKz-4yRTxOFk,1069
29
+ python_general_be_lib-0.8.4.dist-info/METADATA,sha256=RAQiWf6TonlfxsCmXrQY3zgF2W_sREUs9vvNFyul9Bw,2962
30
+ python_general_be_lib-0.8.4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
31
+ python_general_be_lib-0.8.4.dist-info/top_level.txt,sha256=tTZePW8_CNUqSgKFd2SEH72ZbnhS0OYjRsgcv0ikSFY,8
32
+ python_general_be_lib-0.8.4.dist-info/RECORD,,