enforce-rules 3.3.0__tar.gz → 3.3.2__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 (19) hide show
  1. {enforce_rules-3.3.0/src/enforce_rules.egg-info → enforce_rules-3.3.2}/PKG-INFO +2 -2
  2. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/README.md +1 -1
  3. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/pyproject.toml +1 -1
  4. enforce_rules-3.3.2/src/enforce_rules/enforce_rules.pyi +35 -0
  5. {enforce_rules-3.3.0 → enforce_rules-3.3.2/src/enforce_rules.egg-info}/PKG-INFO +2 -2
  6. enforce_rules-3.3.0/src/enforce_rules/enforce_rules.pyi +0 -6
  7. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/LICENSE +0 -0
  8. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/MANIFEST.in +0 -0
  9. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/requirements.txt +0 -0
  10. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/setup.cfg +0 -0
  11. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules/__init__.py +0 -0
  12. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules/__init__.pyi +0 -0
  13. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules/enforce_rules.py +0 -0
  14. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules/py.typed +0 -0
  15. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules.egg-info/SOURCES.txt +0 -0
  16. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules.egg-info/dependency_links.txt +0 -0
  17. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules.egg-info/requires.txt +0 -0
  18. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/src/enforce_rules.egg-info/top_level.txt +0 -0
  19. {enforce_rules-3.3.0 → enforce_rules-3.3.2}/tests/test_enforce_rules.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: enforce-rules
3
- Version: 3.3.0
3
+ Version: 3.3.2
4
4
  Summary: Runtime rule validation for Python using dictionary-based constraints.
5
5
  Author: Jake Loepker, Microsoft Copilot (AI Assistant)
6
6
  License: BSD 3-Clause License
@@ -68,7 +68,7 @@ MAJOR: 3
68
68
 
69
69
  MINOR: 3
70
70
 
71
- PATCH: 0
71
+ PATCH: 2
72
72
 
73
73
  If you need to catch up, you can see the full version history in the [CHANGELOG](https://github.com/Loepker-James/enforce-rules/blob/main/CHANGELOG.md).
74
74
 
@@ -7,7 +7,7 @@ MAJOR: 3
7
7
 
8
8
  MINOR: 3
9
9
 
10
- PATCH: 0
10
+ PATCH: 2
11
11
 
12
12
  If you need to catch up, you can see the full version history in the [CHANGELOG](https://github.com/Loepker-James/enforce-rules/blob/main/CHANGELOG.md).
13
13
 
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "enforce-rules"
3
- version = "3.3.0"
3
+ version = "3.3.2"
4
4
  description = "Runtime rule validation for Python using dictionary-based constraints."
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.10"
@@ -0,0 +1,35 @@
1
+ from typing import TypeVar, Dict, TypedDict, Callable, Literal
2
+
3
+ _T = TypeVar("_T")
4
+
5
+ class _ValidateDict(TypedDict, total=False):
6
+ length: int
7
+ min_length: int
8
+ max_length: int
9
+ min: int | float
10
+ max: int | float
11
+ allowed_values: Iterable
12
+ invariant: bool
13
+ all_same: bool
14
+ all_unique: bool
15
+ non_empty: bool
16
+ no_nulls: bool
17
+ sorted: bool
18
+ increasing: bool
19
+ decreasing: bool
20
+ sum_min: int | float
21
+ sum_max: int | float
22
+ element_min: int | float
23
+ element_max: int | float
24
+ regex: str
25
+ regex_flags: object
26
+ must_be_true: Callable[[_T], bool]
27
+ before_date: datetime
28
+ after_date: datetime
29
+ piece_color: bool
30
+ piece_type: Literal[1, 2, 3, 4, 5, 6]
31
+ chess_symbol: Literal["p", "n", "b", "r", "q", "k", "P", "N", "B", "R", "Q", "K"]
32
+ is_password: bool
33
+
34
+ def validate(value: _T, rules: _ValidateDict) -> _T: ...
35
+ def is_valid(value: _T, rules: _ValidateDict) -> _T: ...
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: enforce-rules
3
- Version: 3.3.0
3
+ Version: 3.3.2
4
4
  Summary: Runtime rule validation for Python using dictionary-based constraints.
5
5
  Author: Jake Loepker, Microsoft Copilot (AI Assistant)
6
6
  License: BSD 3-Clause License
@@ -68,7 +68,7 @@ MAJOR: 3
68
68
 
69
69
  MINOR: 3
70
70
 
71
- PATCH: 0
71
+ PATCH: 2
72
72
 
73
73
  If you need to catch up, you can see the full version history in the [CHANGELOG](https://github.com/Loepker-James/enforce-rules/blob/main/CHANGELOG.md).
74
74
 
@@ -1,6 +0,0 @@
1
- from typing import TypeVar, Dict
2
-
3
- _T = TypeVar("_T")
4
-
5
- def validate(value: _T, rules: Dict[str, object]) -> _T: ...
6
- def is_valid(value: _T, rules: Dict[str, object]) -> _T: ...
File without changes
File without changes
File without changes