pyspiral 0.6.2__cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl → 0.6.3__cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.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.
- {pyspiral-0.6.2.dist-info → pyspiral-0.6.3.dist-info}/METADATA +1 -1
- {pyspiral-0.6.2.dist-info → pyspiral-0.6.3.dist-info}/RECORD +6 -6
- spiral/_lib.abi3.so +0 -0
- spiral/debug/scan.py +21 -3
- {pyspiral-0.6.2.dist-info → pyspiral-0.6.3.dist-info}/WHEEL +0 -0
- {pyspiral-0.6.2.dist-info → pyspiral-0.6.3.dist-info}/entry_points.txt +0 -0
@@ -1,8 +1,8 @@
|
|
1
|
-
pyspiral-0.6.
|
2
|
-
pyspiral-0.6.
|
3
|
-
pyspiral-0.6.
|
1
|
+
pyspiral-0.6.3.dist-info/METADATA,sha256=93TxmaIrXRNq5xlBQAx76ClIGjWdnh9bfL_f6KrB9K0,1836
|
2
|
+
pyspiral-0.6.3.dist-info/WHEEL,sha256=PxcKzGLVtZeSnGJDErQ-Emkn2AvBXbmzIogfnaf7-q8,130
|
3
|
+
pyspiral-0.6.3.dist-info/entry_points.txt,sha256=uft7u-a6g40NLt4Q6BleWbK4NY0M8nZuYPpP8DV0EOk,45
|
4
4
|
spiral/__init__.py,sha256=5c0faqg-kHZBDwriQ7LzLAMcFolIucp-IA1EzNvCZ3k,711
|
5
|
-
spiral/_lib.abi3.so,sha256=
|
5
|
+
spiral/_lib.abi3.so,sha256=01snL6F8rV5RN7cEd8qp0jEukg_M2887lIfA1K2W-l0,55696760
|
6
6
|
spiral/adbc.py,sha256=7IxfWIeQN-fh0W5OdN_PP2x3pzQYg6ZUOLsHg3jktqw,14842
|
7
7
|
spiral/api/__init__.py,sha256=ULBlVq3PnfNOO6T5naE_ULmmii-83--qTuN2PpAUQN0,2241
|
8
8
|
spiral/api/admin.py,sha256=A1iVR1XYJSObZivPAD5UzmPuMgupXc9kaHNYYa_kwfs,585
|
@@ -48,7 +48,7 @@ spiral/datetime_.py,sha256=1TA1RYIRU22qcUuipIjVhAtGnPDVn2z9WttuhkmfkwY,964
|
|
48
48
|
spiral/debug/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
49
49
|
spiral/debug/manifests.py,sha256=oaPB4534pQdqvPXCZetVNSvvhpdXTrv_1pN-_bAkeAo,2893
|
50
50
|
spiral/debug/metrics.py,sha256=XdRDcjggtsLNGCAjam6IxG9072pz_d2C8iLApNRFUtk,2044
|
51
|
-
spiral/debug/scan.py,sha256=
|
51
|
+
spiral/debug/scan.py,sha256=UEm_aRnql5pwDPTpZgakMLNjlzkKL4RurBFFqH_BLAQ,9526
|
52
52
|
spiral/expressions/__init__.py,sha256=T8PIb0_UB9kynK0dpWbUD4No5lKRTG-wKnao8xOcXjY,6381
|
53
53
|
spiral/expressions/base.py,sha256=OOUDrbkLBE0lSkAmM-6FP2F2N8zhN_in3S_UDrWLDeQ,4805
|
54
54
|
spiral/expressions/http.py,sha256=begUydWoFHEqjeLkATvI_v66Ez6_rR-OQBWO5cHbb9c,2742
|
@@ -96,4 +96,4 @@ spiral/table.py,sha256=ZQFq5tuovDjQcpi38b5FUMuHNGI5XV0MnZbC6vbza1o,10312
|
|
96
96
|
spiral/text_index.py,sha256=FQ9rgIEGLSJryS9lFdMhKtPFey18BXoWbPXyvZPJJ04,442
|
97
97
|
spiral/transaction.py,sha256=nSykH4UGs9hGtWuSWK9YyT9jfEuvzfkKoUgMM5Xt4zU,1841
|
98
98
|
spiral/types_.py,sha256=W_jyO7F6rpPiH69jhgSgV7OxQZbOlb1Ho3InpKUP6Eo,155
|
99
|
-
pyspiral-0.6.
|
99
|
+
pyspiral-0.6.3.dist-info/RECORD,,
|
spiral/_lib.abi3.so
CHANGED
Binary file
|
spiral/debug/scan.py
CHANGED
@@ -146,14 +146,32 @@ def _get_fragment_color(manifest_file: FragmentFile, color_index, total_colors):
|
|
146
146
|
return cm.viridis(color_index / total_colors)
|
147
147
|
|
148
148
|
|
149
|
+
def _get_human_size(size_bytes: int) -> str:
|
150
|
+
# Convert bytes to a human-readable format
|
151
|
+
for unit in ["B", "KB", "MB", "GB", "TB"]:
|
152
|
+
if size_bytes < 1024:
|
153
|
+
return f"{size_bytes:.2f} {unit}"
|
154
|
+
size_bytes /= 1024
|
155
|
+
return f"{size_bytes:.2f} PB"
|
156
|
+
|
157
|
+
|
158
|
+
def _maybe_truncate(text, max_length: int = 30) -> str:
|
159
|
+
text = str(text)
|
160
|
+
if len(text) <= max_length:
|
161
|
+
return text
|
162
|
+
|
163
|
+
half_length = (max_length - 3) // 2
|
164
|
+
return text[:half_length] + "..." + text[-half_length:]
|
165
|
+
|
166
|
+
|
149
167
|
def _get_fragment_legend(manifest_file: FragmentFile):
|
150
168
|
return "\n".join(
|
151
169
|
[
|
152
170
|
f"id: {manifest_file.id}",
|
153
|
-
f"size: {manifest_file.size_bytes
|
171
|
+
f"size: {_get_human_size(manifest_file.size_bytes)} ({manifest_file.size_bytes} bytes)",
|
154
172
|
f"key_span: {manifest_file.key_span}",
|
155
|
-
f"key_min: {manifest_file.key_extent.min}",
|
156
|
-
f"key_max: {manifest_file.key_extent.max}",
|
173
|
+
f"key_min: {_maybe_truncate(manifest_file.key_extent.min)}",
|
174
|
+
f"key_max: {_maybe_truncate(manifest_file.key_extent.max)}",
|
157
175
|
f"format: {manifest_file.format}",
|
158
176
|
f"level: {manifest_file.level}",
|
159
177
|
f"committed_at: {_format_timestamp(manifest_file.committed_at)}",
|
File without changes
|
File without changes
|