pointblank 0.16.0__py3-none-any.whl → 0.18.0__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.
- pointblank/__init__.py +2 -0
- pointblank/_agg.py +120 -0
- pointblank/_constants.py +207 -6
- pointblank/_constants_translations.py +1302 -0
- pointblank/_datascan_utils.py +28 -10
- pointblank/_interrogation.py +216 -139
- pointblank/_typing.py +12 -0
- pointblank/_utils.py +81 -44
- pointblank/_utils_ai.py +4 -5
- pointblank/_utils_check_args.py +3 -3
- pointblank/_utils_llms_txt.py +41 -2
- pointblank/actions.py +1 -1
- pointblank/assistant.py +2 -3
- pointblank/cli.py +1 -1
- pointblank/column.py +162 -46
- pointblank/data/api-docs.txt +2957 -50
- pointblank/datascan.py +17 -17
- pointblank/draft.py +2 -3
- pointblank/scan_profile.py +2 -1
- pointblank/schema.py +61 -20
- pointblank/thresholds.py +15 -13
- pointblank/validate.py +2280 -410
- pointblank/validate.pyi +1104 -0
- pointblank/yaml.py +15 -8
- {pointblank-0.16.0.dist-info → pointblank-0.18.0.dist-info}/METADATA +7 -2
- {pointblank-0.16.0.dist-info → pointblank-0.18.0.dist-info}/RECORD +30 -28
- {pointblank-0.16.0.dist-info → pointblank-0.18.0.dist-info}/licenses/LICENSE +1 -1
- {pointblank-0.16.0.dist-info → pointblank-0.18.0.dist-info}/WHEEL +0 -0
- {pointblank-0.16.0.dist-info → pointblank-0.18.0.dist-info}/entry_points.txt +0 -0
- {pointblank-0.16.0.dist-info → pointblank-0.18.0.dist-info}/top_level.txt +0 -0
pointblank/_datascan_utils.py
CHANGED
|
@@ -17,11 +17,15 @@ def _round_to_sig_figs(value: float, sig_figs: int) -> float:
|
|
|
17
17
|
|
|
18
18
|
def _compact_integer_fmt(value: float | int) -> str:
|
|
19
19
|
if value == 0:
|
|
20
|
-
formatted = "0"
|
|
20
|
+
formatted: str = "0"
|
|
21
21
|
elif abs(value) >= 1 and abs(value) < 10_000:
|
|
22
|
-
formatted = fmt_integer(value, use_seps=False)
|
|
22
|
+
formatted = fmt_integer(value, use_seps=False)
|
|
23
|
+
assert isinstance(formatted, list)
|
|
24
|
+
formatted: str = formatted[0]
|
|
23
25
|
else:
|
|
24
|
-
formatted = fmt_scientific(value, decimals=1, exp_style="E1")
|
|
26
|
+
formatted = fmt_scientific(value, decimals=1, exp_style="E1")
|
|
27
|
+
assert isinstance(formatted, list)
|
|
28
|
+
formatted: str = formatted[0]
|
|
25
29
|
|
|
26
30
|
return formatted
|
|
27
31
|
|
|
@@ -30,15 +34,25 @@ def _compact_decimal_fmt(value: float | int) -> str:
|
|
|
30
34
|
if value == 0:
|
|
31
35
|
formatted = "0.00"
|
|
32
36
|
elif abs(value) < 1 and abs(value) >= 0.01:
|
|
33
|
-
formatted = fmt_number(value, decimals=2)
|
|
37
|
+
formatted = fmt_number(value, decimals=2)
|
|
38
|
+
assert isinstance(formatted, list)
|
|
39
|
+
formatted: str = formatted[0]
|
|
34
40
|
elif abs(value) < 0.01:
|
|
35
|
-
formatted = fmt_scientific(value, decimals=1, exp_style="E1")
|
|
41
|
+
formatted = fmt_scientific(value, decimals=1, exp_style="E1")
|
|
42
|
+
assert isinstance(formatted, list)
|
|
43
|
+
formatted: str = formatted[0]
|
|
36
44
|
elif abs(value) >= 1 and abs(value) < 1000:
|
|
37
|
-
formatted = fmt_number(value, n_sigfig=3)
|
|
45
|
+
formatted = fmt_number(value, n_sigfig=3)
|
|
46
|
+
assert isinstance(formatted, list)
|
|
47
|
+
formatted: str = formatted[0]
|
|
38
48
|
elif abs(value) >= 1000 and abs(value) < 10_000:
|
|
39
|
-
formatted = fmt_number(value, decimals=0, use_seps=False)
|
|
49
|
+
formatted = fmt_number(value, decimals=0, use_seps=False)
|
|
50
|
+
assert isinstance(formatted, list)
|
|
51
|
+
formatted: str = formatted[0]
|
|
40
52
|
else:
|
|
41
|
-
formatted = fmt_scientific(value, decimals=1, exp_style="E1")
|
|
53
|
+
formatted = fmt_scientific(value, decimals=1, exp_style="E1")
|
|
54
|
+
assert isinstance(formatted, list)
|
|
55
|
+
formatted: str = formatted[0]
|
|
42
56
|
|
|
43
57
|
return formatted
|
|
44
58
|
|
|
@@ -54,7 +68,9 @@ def _compact_0_1_fmt(value: float | int | None) -> str | None:
|
|
|
54
68
|
return " 1.00"
|
|
55
69
|
|
|
56
70
|
if abs(value) < 1 and abs(value) >= 0.01:
|
|
57
|
-
|
|
71
|
+
formatted = fmt_number(value, decimals=2)
|
|
72
|
+
assert isinstance(formatted, list)
|
|
73
|
+
return " " + formatted[0]
|
|
58
74
|
|
|
59
75
|
if abs(value) < 0.01:
|
|
60
76
|
return "<0.01"
|
|
@@ -62,4 +78,6 @@ def _compact_0_1_fmt(value: float | int | None) -> str | None:
|
|
|
62
78
|
if abs(value) > 0.99:
|
|
63
79
|
return ">0.99"
|
|
64
80
|
|
|
65
|
-
|
|
81
|
+
formatted = fmt_number(value, n_sigfig=3)
|
|
82
|
+
assert isinstance(formatted, list)
|
|
83
|
+
return formatted[0]
|