wexample-orm 1.1.0__tar.gz → 1.2.1__tar.gz

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.
Files changed (20) hide show
  1. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/PKG-INFO +4 -4
  2. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/README.md +2 -2
  3. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/pyproject.toml +2 -2
  4. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/common/abstract_repositories_manager.py +3 -2
  5. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/__init__.py +0 -0
  6. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/common/__init__.py +0 -0
  7. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/entity/__init__.py +0 -0
  8. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/entity/abstract_entity.py +0 -0
  9. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/exception/__init__.py +0 -0
  10. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/exception/repository_session_missing_exception.py +0 -0
  11. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/exception/unknown_repository_exception.py +0 -0
  12. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/py.typed +0 -0
  13. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/repository/__init__.py +0 -0
  14. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/repository/abstract_repository.py +0 -0
  15. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/session/__init__.py +0 -0
  16. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/session/abstract_session_factory.py +0 -0
  17. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/testing/__init__.py +0 -0
  18. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/src/wexample_orm/testing/sqlite.py +0 -0
  19. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/tests/__init__.py +0 -0
  20. {wexample_orm-1.1.0 → wexample_orm-1.2.1}/tests/test_abstract.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: wexample-orm
3
- Version: 1.1.0
3
+ Version: 1.2.1
4
4
  Summary: ORM abstractions on top of SQLAlchemy, PostgreSQL-first (psycopg bundled).
5
5
  Author-Email: weeger <contact@wexample.com>
6
6
  License: MIT
@@ -12,7 +12,7 @@ Requires-Python: >=3.10
12
12
  Requires-Dist: attrs>=23.1.0
13
13
  Requires-Dist: psycopg[binary]>=3.2
14
14
  Requires-Dist: sqlalchemy<3,>=2
15
- Requires-Dist: wexample-helpers>=16.2.0
15
+ Requires-Dist: wexample-helpers>=17.2.0
16
16
  Provides-Extra: dev
17
17
  Requires-Dist: pytest; extra == "dev"
18
18
  Requires-Dist: pytest-cov; extra == "dev"
@@ -20,7 +20,7 @@ Description-Content-Type: text/markdown
20
20
 
21
21
  # orm
22
22
 
23
- Version: 1.1.0
23
+ Version: 1.2.1
24
24
 
25
25
  ORM abstractions on top of SQLAlchemy, PostgreSQL-first (psycopg bundled).
26
26
 
@@ -103,7 +103,7 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
103
103
  - attrs: >=23.1.0
104
104
  - psycopg: >=3.2
105
105
  - sqlalchemy: <3,>=2
106
- - wexample-helpers: >=16.2.0
106
+ - wexample-helpers: >=17.2.0
107
107
 
108
108
  ## Versioning & Compatibility Policy
109
109
 
@@ -1,6 +1,6 @@
1
1
  # orm
2
2
 
3
- Version: 1.1.0
3
+ Version: 1.2.1
4
4
 
5
5
  ORM abstractions on top of SQLAlchemy, PostgreSQL-first (psycopg bundled).
6
6
 
@@ -83,7 +83,7 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
83
83
  - attrs: >=23.1.0
84
84
  - psycopg: >=3.2
85
85
  - sqlalchemy: <3,>=2
86
- - wexample-helpers: >=16.2.0
86
+ - wexample-helpers: >=17.2.0
87
87
 
88
88
  ## Versioning & Compatibility Policy
89
89
 
@@ -6,7 +6,7 @@ build-backend = "pdm.backend"
6
6
 
7
7
  [project]
8
8
  name = "wexample-orm"
9
- version = "1.1.0"
9
+ version = "1.2.1"
10
10
  description = "ORM abstractions on top of SQLAlchemy, PostgreSQL-first (psycopg bundled)."
11
11
  authors = [
12
12
  { name = "weeger", email = "contact@wexample.com" },
@@ -21,7 +21,7 @@ dependencies = [
21
21
  "attrs>=23.1.0",
22
22
  "psycopg[binary]>=3.2",
23
23
  "sqlalchemy>=2,<3",
24
- "wexample-helpers>=16.2.0",
24
+ "wexample-helpers>=17.2.0",
25
25
  ]
26
26
 
27
27
  [project.readme]
@@ -28,8 +28,9 @@ class AbstractRepositoriesManager(BaseClass):
28
28
  )
29
29
 
30
30
  def get(self, entity_type: type[AbstractEntity]) -> AbstractRepository:
31
- if entity_type in self._instances:
32
- return self._instances[entity_type]
31
+ instance = self._instances.get(entity_type)
32
+ if instance is not None:
33
+ return instance
33
34
 
34
35
  for repository_class in self.repository_classes:
35
36
  if repository_class.get_entity_type() is entity_type: