zstd 1.5.6.2__pp38-pypy38_pp73-macosx_11_0_arm64.whl → 1.5.6.4__pp38-pypy38_pp73-macosx_11_0_arm64.whl

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,4 @@
1
- Copyright (c) 2015-2022, Sergey Dryabzhinsky, Anton Stuk
1
+ Copyright (c) 2015-2025, Sergey Dryabzhinsky, Anton Stuk
2
2
  All rights reserved.
3
3
 
4
4
  Redistribution and use in source and binary forms, with or without
@@ -0,0 +1,502 @@
1
+ Metadata-Version: 2.1
2
+ Name: zstd
3
+ Version: 1.5.6.4
4
+ Summary: ZSTD Bindings for Python
5
+ Home-page: https://github.com/sergey-dryabzhinsky/python-zstd
6
+ Author: Sergey Dryabzhinsky, Anton Stuk
7
+ Author-email: sergey.dryabzhinsky@gmail.com
8
+ Maintainer: Sergey Dryabzhinsky
9
+ Maintainer-email: sergey.dryabzhinsky@gmail.com
10
+ License: BSD
11
+ Keywords: zstd,zstandard,compression
12
+ Classifier: License :: OSI Approved :: BSD License
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Development Status :: 5 - Production/Stable
15
+ Classifier: Operating System :: POSIX
16
+ Classifier: Programming Language :: C
17
+ Classifier: Programming Language :: Python
18
+ Classifier: Programming Language :: Python :: 2.7
19
+ Classifier: Programming Language :: Python :: 3.4
20
+ Classifier: Programming Language :: Python :: 3.5
21
+ Classifier: Programming Language :: Python :: 3.6
22
+ Classifier: Programming Language :: Python :: 3.7
23
+ Classifier: Programming Language :: Python :: 3.8
24
+ Classifier: Programming Language :: Python :: 3.9
25
+ Classifier: Programming Language :: Python :: 3.10
26
+ Classifier: Programming Language :: Python :: 3.11
27
+ Classifier: Programming Language :: Python :: 3.12
28
+ Classifier: Programming Language :: Python :: 3.13
29
+ Classifier: Programming Language :: Python :: 3.14
30
+ License-File: LICENSE
31
+
32
+ =============
33
+ python-zstd
34
+ =============
35
+
36
+ .. |releaseW| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml/badge.svg?tag=v1.5.6.4
37
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml
38
+
39
+ .. |masterW| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml/badge.svg
40
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml
41
+
42
+ .. |cpython27x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython27_x86_64.yml/badge.svg
43
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython27_x86_64.yml
44
+
45
+ .. |cpython27x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython27_x86.yml/badge.svg
46
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython27_x86.yml
47
+
48
+ .. |cpython27armhf| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython27_armhf.yml/badge.svg
49
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython27_armhf.yml
50
+
51
+ .. |cpython34x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython34_x86.yml/badge.svg
52
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython34_x86.yml
53
+
54
+ .. |cpython34x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython34_x86_64.yml/badge.svg
55
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython34_x86_64.yml
56
+
57
+ .. |cpython35x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython35_x86.yml/badge.svg
58
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython35_x86.yml
59
+
60
+ .. |cpython35x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython35_x86_64.yml/badge.svg
61
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython35_x86_64.yml
62
+
63
+ .. |cpython36x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython36_x86.yml/badge.svg
64
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython36_x86.yml
65
+
66
+ .. |cpython36x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython36_x86_64.yml/badge.svg
67
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython36_x86_64.yml
68
+
69
+ .. |cpython37x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython37_x86.yml/badge.svg
70
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython37_x86.yml
71
+
72
+ .. |cpython37x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython37_x86_64_u24.yml/badge.svg
73
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython37_x86_64_u24.yml
74
+
75
+ .. |cpython38x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython38_x86.yml/badge.svg
76
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython38_x86.yml
77
+
78
+ .. |cpython38x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython38_x86_64_u24.yml/badge.svg
79
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython38_x86_64_u24.yml
80
+
81
+ .. |cpython39x86| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython39_x86.yml/badge.svg
82
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython39_x86.yml
83
+
84
+ .. |cpython39x64| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython39_x86_64_u24.yml/badge.svg
85
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython39_x86_64_u24.yml
86
+
87
+ .. |cpython310x86u16| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython310_x86_u16.yml/badge.svg
88
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython310_x86_u16.yml
89
+
90
+ .. |cpython310x64u20| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython310_x86_64_u24.yml/badge.svg
91
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython310_x86_64_u24.yml
92
+
93
+ .. |cpython311x86u16| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython311_x86_u16.yml/badge.svg
94
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython311_x86_u16.yml
95
+
96
+ .. |cpython311x64u20| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython311_x86_64_u24.yml/badge.svg
97
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython311_x86_64_u24.yml
98
+
99
+ .. |cpython312x86u16| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython312_x86_u16.yml/badge.svg
100
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython312_x86_u16.yml
101
+
102
+ .. |cpython312x64u20| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython312_x86_64_u20.yml/badge.svg
103
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython312_x86_64_u20.yml
104
+
105
+ .. |cpython313x64u20| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython313_x86_64_u24.yml/badge.svg
106
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython313_x86_64_u24.yml
107
+
108
+ .. |cpython314x64u20| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython314_x86_64_u24.yml/badge.svg
109
+ :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/Build_wheels_for_cpython314_x86_64_u24.yml
110
+
111
+ +----------------------+---------------------+
112
+ | wheels for: | status |
113
+ +======================+=====================+
114
+ | cpython 2.7 x86 | |cpython27x86| |
115
+ +----------------------+---------------------+
116
+ | cpython 2.7 x64 | |cpython27x64| |
117
+ +----------------------+---------------------+
118
+ | cpython 2.7 armhf | |cpython27armhf| |
119
+ +----------------------+---------------------+
120
+ | cpython 3.4 x86 | |cpython34x86| |
121
+ +----------------------+---------------------+
122
+ | cpython 3.4 x64 | |cpython34x64| |
123
+ +----------------------+---------------------+
124
+ | cpython 3.5 x86 | |cpython35x86| |
125
+ +----------------------+---------------------+
126
+ | cpython 3.5 x64 | |cpython35x64| |
127
+ +----------------------+---------------------+
128
+ | cpython 3.6 x86 | |cpython36x86| |
129
+ +----------------------+---------------------+
130
+ | cpython 3.6 x64 | |cpython36x64| |
131
+ +----------------------+---------------------+
132
+ | cpython 3.7 x86 | |cpython37x86| |
133
+ +----------------------+---------------------+
134
+ | cpython 3.7 x64 u24 | |cpython37x64| |
135
+ +----------------------+---------------------+
136
+ | cpython 3.8 x86 | |cpython38x86| |
137
+ +----------------------+---------------------+
138
+ | cpython 3.8 x64 u24 | |cpython38x64| |
139
+ +----------------------+---------------------+
140
+ | cpython 3.9 x86 | |cpython39x86| |
141
+ +----------------------+---------------------+
142
+ | cpython 3.9 x64 u24 | |cpython39x64| |
143
+ +----------------------+---------------------+
144
+ | cpython 3.10 x86 u16 | |cpython310x86u16| |
145
+ +----------------------+---------------------+
146
+ | cpython 3.10 x64 u24 | |cpython310x64u20| |
147
+ +----------------------+---------------------+
148
+ | cpython 3.11 x86 u16 | |cpython311x86u16| |
149
+ +----------------------+---------------------+
150
+ | cpython 3.11 x64 u24 | |cpython311x64u20| |
151
+ +----------------------+---------------------+
152
+ | cpython 3.12 x86 u16 | |cpython312x86u16| |
153
+ +----------------------+---------------------+
154
+ | cpython 3.12 x64 u24 | |cpython312x64u20| |
155
+ +----------------------+---------------------+
156
+ | cpython 3.13 x64 u24 | |cpython313x64u20| |
157
+ +----------------------+---------------------+
158
+ | cpython 3.14 x64 u24 | |cpython314x64u20| |
159
+ +----------------------+---------------------+
160
+ | Release | |releaseW| |
161
+ | 1.5.6.4 | |
162
+ +----------------------+---------------------+
163
+ | Master | |masterW| |
164
+ +----------------------+---------------------+
165
+
166
+ Simple python bindings to Yann Collet ZSTD compression library.
167
+
168
+ **Zstd**, short for Zstandard, is a new lossless compression algorithm,
169
+ which provides both good compression ratio *and* speed for your standard compression needs.
170
+ "Standard" translates into everyday situations which neither look for highest possible ratio
171
+ (which LZMA and ZPAQ cover) nor extreme speeds (which LZ4 covers).
172
+
173
+ It is provided as a BSD-license package, hosted on GitHub_.
174
+
175
+ .. _GitHub: https://github.com/facebook/zstd
176
+
177
+
178
+ WARNING!!!
179
+ ----------
180
+
181
+ If you setup 1.0.0.99.1 version - remove it manualy to able to update.
182
+ PIP matching version strings not tuple of numbers.
183
+
184
+ Result generated by versions prior to 1.0.0.99.1 is not compatible with orignial Zstd
185
+ by any means. It generates custom header and can be read only by zstd python module.
186
+
187
+ As of 1.0.0.99.1 version it uses standard Zstd output, not modified.
188
+
189
+ To prevent data loss there is two functions now: ```compress_old``` and ```decompress_old```.
190
+ They are works just like in old versions prior to 1.0.0.99.1.
191
+
192
+ As of 1.1.4 version module build without them by default.
193
+
194
+ As of 1.3.4 version these functions are deprecated and will be removed in future releases.
195
+
196
+ As of 1.5.0 version these functions are removed.
197
+
198
+
199
+ DISCLAIMER
200
+ __________
201
+
202
+ These python bindings are kept simple and blunt.
203
+
204
+ Support of dictionaries and streaming is not planned.
205
+
206
+
207
+ LINKS
208
+ -----
209
+
210
+ * Zstandard: https://github.com/facebook/zstd
211
+ * More full-featured and compatible with Zstandard python bindings by Gregory Szorc: https://github.com/indygreg/python-zstandard
212
+
213
+
214
+ Build from source
215
+ -----------------
216
+
217
+ >>> $ git clone https://github.com/sergey-dryabzhinsky/python-zstd
218
+ >>> $ git submodule update --init
219
+ >>> $ apt-get install python-dev python3-dev python-setuptools python3-setuptools
220
+ >>> $ python setup.py build_ext clean
221
+ >>> $ python3 setup.py build_ext clean
222
+
223
+ And you need to install `libzstd` developer files at least version *1.4.0*:
224
+
225
+ >>> $ dnf install -y libzstd-devel
226
+ # or
227
+ >>> $ apt install -y libzstd-dev
228
+ # or
229
+ >>> $ apk add zstd-dev
230
+
231
+ or do manual installation of zstd from source.
232
+
233
+ Note: Zstd legacy format support disabled by default.
234
+ To build with Zstd legacy versions support - pass ``--legacy`` option to setup.py script:
235
+
236
+ >>> $ python setup.py build_ext --legacy clean
237
+
238
+ When using a PEP 517 builder you can use ``ZSTD_LEGACY`` environment variable instead:
239
+
240
+ >>> $ ZSTD_LEGACY=1 python -m build -w
241
+
242
+ Note: Python-Zstd legacy format support removed since 1.5.0.
243
+ If you need to convert old data - checkout 1.4.9.1 module version. Support of it disabled by default.
244
+ To build with python-zstd legacy format support (pre 1.1.2) - pass ``--pyzstd-legacy`` option to setup.py script:
245
+
246
+ >>> $ python setup.py build_ext --pyzstd-legacy clean
247
+
248
+ But beware! Legacy formats support state is unknown in this case.
249
+ And if your version not equal with python-zstd - tests may not pass.
250
+
251
+ If you're scared of threads you may pass option `--libzstd-no-threads`:
252
+
253
+ >>> $ python setup.py build_ext --libzstd-no-threads clean
254
+
255
+ When using a PEP 517 builder you can use ``ZSTD_THREADS`` environment variable instead:
256
+
257
+ >>> $ ZSTD_THREADS=0 python -m build -w
258
+
259
+ If you're meet some cpu instruction errorrs you may try to disable built-in optimizations and pass option `--libzstd-no-use-asm`:
260
+
261
+ >>> $ python setup.py build_ext --libzstd-no-use-asm clean
262
+
263
+ Or add more speed with option `--libzstd-use-asm-bmi2` to use instructions for new AMD CPU.
264
+ When using a PEP 517 builder you can use ``ZSTD_ASM`` environment variable instead:
265
+ And ``ZST_ASM_BMI2=1`` too for bmi2 use.
266
+
267
+ >>> $ ZSTD_ASM=0 python -m build -w
268
+
269
+ If you want bo build smaller module by size try to use option `--small`, but it will work slower.
270
+
271
+ >>> $ python setup.py build_ext --small clean
272
+
273
+ When using a PEP 517 builder you can use ``ZSTD_SMALL`` environment variable instead:
274
+
275
+ >>> $ ZSTD_SMALL=1 python -m build -w
276
+
277
+ If you want to build with existing distribution of libzstd just add ``--external`` option
278
+
279
+ >>> $ python setup.py build_ext --external clean
280
+
281
+ When using a PEP 517 builder you can use ``ZSTD_EXTERNAL`` environment variable instead:
282
+
283
+ >>> $ ZSTD_EXTERNAL=1 python -m build -w
284
+
285
+ If paths to header file ``zstd.h`` and libraries is uncommon - use common ``build`` params:
286
+ --libraries --include-dirs --library-dirs.
287
+
288
+ >>> $ python setup.py build_ext --external --include-dirs /opt/zstd/usr/include --libraries zstd --library-dirs /opt/zstd/lib clean
289
+
290
+ But If you want to force build with bundled distribution of libzstd just add ``--
291
+ libzstd-bundled`` option
292
+
293
+ >>> $ python setup.py build_ext --libzstd-bundled clean
294
+
295
+ When using a PEP 517 builder you can use ``ZSTD_BUNDLED`` environment variable instead:
296
+
297
+ >>> $ ZSTD_BUNDLED=1 python -m build -w
298
+
299
+ If you want to check if build w/o any warnings just add ``--
300
+ all-warnings`` option
301
+
302
+ >>> $ python setup.py build_ext --all-warnings clean
303
+
304
+ When using a PEP 517 builder you can use ``ZSTD_WARNINGS`` environment variable instead:
305
+
306
+ >>> $ ZSTD_WARNINGS=1 python -m build -w
307
+
308
+ Install from pypi
309
+ -----------------
310
+
311
+ >>> # for Python 2.7+
312
+ >>> $ pip install zstd
313
+ >>> # or for Python 3.4+
314
+ >>> $ pip3 install zstd
315
+
316
+
317
+ API
318
+ ___
319
+
320
+ Error
321
+ Standard python Exception for zstd module
322
+
323
+ ZSTD_compress (data[, level, threads, strict]): string|bytes
324
+ Function, compress input data block via mutliple threads, return compressed block, or raises Error.
325
+
326
+ Params:
327
+
328
+ * **data**: string|bytes - input data block, length limited by 2Gb by Python API
329
+ * **level**: int - compression level, ultra-fast levels from -100 (ultra) to -1 (fast) available since zstd-1.3.4, and from 1 (fast) to 22 (slowest), 0 or unset - means default (3). Default - 3.
330
+ * **threads**: int - how many threads to use, from 0 to 200, 0 or unset - auto-tune by cpu cores count. Default - 0. Since: 1.4.4.1
331
+ * **strict**: int - strict behaviour, raise `zstd.Error` if threads number or compression level is beyond limitations. Default - 0. Since: 1.5.6.3
332
+
333
+ Aliases:
334
+ - *compress(...)*,
335
+ - *dumps(...)*,
336
+ - *encode(...)* since: 1.5.6.2
337
+
338
+ Exception if:
339
+ - level bigger than max level
340
+
341
+ Max number of threads:
342
+ - 32bit system: 64
343
+ - 64bit system: 256
344
+ If provided bigger number - silently set maximber (since 1.5.4.1)
345
+
346
+ Since: 0.1
347
+
348
+ ZSTD_uncompress (data): string|bytes
349
+ Function, decompress input compressed data block, return decompressed block, or raises Error.
350
+
351
+ Support compressed data with multiple/concatenated frames (blocks) (since 1.5.5.1).
352
+
353
+ Params:
354
+
355
+ * **data**: string|bytes - input compressed data block, length limited by 2Gb by Python API
356
+
357
+ Aliases:
358
+ - *decompress(...)*,
359
+ - *uncompress(...)*,
360
+ - *loads(...)*,
361
+ - *decode(...)* since: 1.5.6.2
362
+
363
+ Since: 0.1
364
+
365
+ ZSTD_check (data): int
366
+ Function, checks if input is zstd compressed data block, returns 1 if yes, 0 if no.
367
+
368
+ Support compressed data with multiple/concatenated frames (blocks) .
369
+
370
+ Params:
371
+
372
+ * **data**: string|bytes - input compressed data block, length limited by 2Gb by Python API
373
+
374
+ Aliases:
375
+ - *check(...)*,
376
+ - *verify(...)* since: 1.5.6.3
377
+
378
+ Since: 1.5.6.2
379
+
380
+ version (): string|bytes
381
+ Returns this module doted version string.
382
+
383
+ The first three digits are folow libzstd version.
384
+ Fourth digit - module revision number for that version.
385
+
386
+ Since: 1.3.4.3
387
+
388
+ ZSTD_version (): string|bytes
389
+ Returns ZSTD library doted version string.
390
+
391
+ Since: 1.3.4.3
392
+
393
+ ZSTD_version_number (): int
394
+ Returns ZSTD library version in format: MAJOR*100*100 + MINOR*100 + RELEASE.
395
+
396
+ Since: 1.3.4.3
397
+
398
+ ZSTD_threads_count (): int
399
+ Returns ZSTD determined CPU cores count.
400
+
401
+ Since: 1.5.4.1
402
+
403
+ ZSTD_max_threads_count (): int
404
+ Returns ZSTD library determined maximum working threads count.
405
+
406
+ Since: 1.5.4.1
407
+
408
+ ZSTD_max_compression_level (): int
409
+ Returns ZSTD library determined maximum number of compression level .
410
+
411
+ Since: 1.5.6.3
412
+
413
+ ZSTD_min_compression_level (): int
414
+ Returns ZSTD library determined minimum number of compression level .
415
+
416
+ Since: 1.5.6.3
417
+
418
+ ZSTD_external (): int
419
+ Returns 0 of 1 if ZSTD library linked as external.
420
+
421
+ Since: 1.5.0.2
422
+
423
+ ZSTD_legacy_support (): int
424
+ Returns 0 of 1 if ZSTD library built with legacy formats support.
425
+
426
+ Since: 1.5.6.3
427
+
428
+ ZSTD_with_threads (): int
429
+ Returns 0 of 1 if bundled ZSTD library build with threads support.
430
+
431
+ Since: 1.5.6.2
432
+
433
+ ZSTD_with_asm (): int
434
+ Returns 0 of 1 if bundled ZSTD library build with asm optimization s.
435
+
436
+ Since: 1.5.6.2
437
+
438
+
439
+ Removed
440
+ _______
441
+
442
+ ZSTD_compress_old (data[, level]): string|bytes
443
+ Function, compress input data block, return compressed block, or raises Error.
444
+
445
+ **DEPRECATED**: Returns not compatible with ZSTD block header
446
+
447
+ **REMOVED**: since 1.5.0
448
+
449
+ Params:
450
+
451
+ * **data**: string|bytes - input data block, length limited by 2Gb by Python API
452
+ * **level**: int - compression level, ultra-fast levels from -5 (ultra) to -1 (fast) available since zstd-1.3.4, and from 1 (fast) to 22 (slowest), 0 or unset - means default (3). Default - 3.
453
+
454
+ Since: 1.0.0.99.1
455
+
456
+ ZSTD_uncompress_old (data): string|bytes
457
+ Function, decompress input compressed data block, return decompressed block, or raises Error.
458
+
459
+ **DEPRECATED**: Accepts data with not compatible with ZSTD block header
460
+
461
+ **REMOVED**: since 1.5.0
462
+
463
+ Params:
464
+
465
+ * **data**: string|bytes - input compressed data block, length limited by 2Gb by Python API
466
+
467
+ Since: 1.0.0.99.1
468
+
469
+ Use
470
+ ___
471
+
472
+ Module has simple API:
473
+
474
+ >>> import zstd
475
+ >>> dir(zstd)
476
+ ['Error', 'ZSTD_compress', 'ZSTD_external', 'ZSTD_uncompress', 'ZSTD_version', 'ZSTD_version_number', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'compress', 'decompress', 'dumps', 'loads', 'uncompress', 'version']
477
+ >>> zstd.version()
478
+ '1.5.1.0'
479
+ >>> zstd.ZSTD_version()
480
+ '1.5.1'
481
+ >>> zstd.ZSTD_version_number()
482
+ 10501
483
+ >>> zstd.ZSTD_external()
484
+ 0
485
+
486
+ In python2
487
+
488
+ >>> data = "123456qwert"
489
+
490
+ In python3 use bytes
491
+
492
+ >>> data = b"123456qwert"
493
+
494
+
495
+ >>> cdata = zstd.compress(data, 1)
496
+ >>> data == zstd.decompress(cdata)
497
+ True
498
+ >>> cdata_mt = zstd.compress(data, 1, 4)
499
+ >>> cdata == cdata_mt
500
+ True
501
+ >>> data == zstd.decompress(cdata_mt)
502
+ True
@@ -0,0 +1,6 @@
1
+ zstd.pypy38-pp73-darwin.so,sha256=3LglYCYBvXG6QyByp1DdrJ95L130Qh32wRgHr0NTk6M,531768
2
+ zstd-1.5.6.4.dist-info/RECORD,,
3
+ zstd-1.5.6.4.dist-info/LICENSE,sha256=A_byUM9rQx6EXwW0ZpyOoWagiM-m96eBsAQlTo2z6iw,1320
4
+ zstd-1.5.6.4.dist-info/WHEEL,sha256=rOp4SUWva7g42_KOrKAoa56qNv-f3p59x93LQqDJdXU,114
5
+ zstd-1.5.6.4.dist-info/top_level.txt,sha256=DhQX04hbm3dWgbCywpue8ejkkSuxZjpZGkVlo8ca-jM,5
6
+ zstd-1.5.6.4.dist-info/METADATA,sha256=mwgEMZSMRN3VznYqjjZX9ny5DRrdm31A6Z35jpS6gBU,20581
Binary file
@@ -1,334 +0,0 @@
1
- Metadata-Version: 2.1
2
- Name: zstd
3
- Version: 1.5.6.2
4
- Summary: ZSTD Bindings for Python
5
- Home-page: https://github.com/sergey-dryabzhinsky/python-zstd
6
- Author: Sergey Dryabzhinsky, Anton Stuk
7
- Author-email: sergey.dryabzhinsky@gmail.com
8
- Maintainer: Sergey Dryabzhinsky
9
- Maintainer-email: sergey.dryabzhinsky@gmail.com
10
- License: BSD
11
- Keywords: zstd,zstandard,compression
12
- Classifier: License :: OSI Approved :: BSD License
13
- Classifier: Intended Audience :: Developers
14
- Classifier: Development Status :: 5 - Production/Stable
15
- Classifier: Operating System :: POSIX
16
- Classifier: Programming Language :: C
17
- Classifier: Programming Language :: Python
18
- Classifier: Programming Language :: Python :: 2.7
19
- Classifier: Programming Language :: Python :: 3.4
20
- Classifier: Programming Language :: Python :: 3.5
21
- Classifier: Programming Language :: Python :: 3.6
22
- Classifier: Programming Language :: Python :: 3.7
23
- Classifier: Programming Language :: Python :: 3.8
24
- Classifier: Programming Language :: Python :: 3.9
25
- Classifier: Programming Language :: Python :: 3.10
26
- Classifier: Programming Language :: Python :: 3.11
27
- Classifier: Programming Language :: Python :: 3.12
28
- Classifier: Programming Language :: Python :: 3.13
29
- License-File: LICENSE
30
-
31
- 7=============
32
- python-zstd
33
- =============
34
-
35
- .. |releaseW| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml/badge.svg?branch=v1.5.6.2
36
- :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml
37
-
38
- .. |masterW| image:: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml/badge.svg
39
- :target: https://github.com/sergey-dryabzhinsky/python-zstd/actions/workflows/build-wheels.yml
40
-
41
- +---------+------------+
42
- | branch | status |
43
- +=========+============+
44
- | Release | |releaseW| |
45
- +---------+------------+
46
- | Master | |masterW| |
47
- +---------+------------+
48
-
49
- Simple python bindings to Yann Collet ZSTD compression library.
50
-
51
- **Zstd**, short for Zstandard, is a new lossless compression algorithm,
52
- which provides both good compression ratio *and* speed for your standard compression needs.
53
- "Standard" translates into everyday situations which neither look for highest possible ratio
54
- (which LZMA and ZPAQ cover) nor extreme speeds (which LZ4 covers).
55
-
56
- It is provided as a BSD-license package, hosted on GitHub_.
57
-
58
- .. _GitHub: https://github.com/facebook/zstd
59
-
60
-
61
- WARNING!!!
62
- ----------
63
-
64
- If you setup 1.0.0.99.1 version - remove it manualy to able to update.
65
- PIP matching version strings not tuple of numbers.
66
-
67
- Result generated by versions prior to 1.0.0.99.1 is not compatible with orignial Zstd
68
- by any means. It generates custom header and can be read only by zstd python module.
69
-
70
- As of 1.0.0.99.1 version it uses standard Zstd output, not modified.
71
-
72
- To prevent data loss there is two functions now: ```compress_old``` and ```decompress_old```.
73
- They are works just like in old versions prior to 1.0.0.99.1.
74
-
75
- As of 1.1.4 version module build without them by default.
76
-
77
- As of 1.3.4 version these functions are deprecated and will be removed in future releases.
78
-
79
- As of 1.5.0 version these functions are removed.
80
-
81
-
82
- DISCLAIMER
83
- __________
84
-
85
- These python bindings are kept simple and blunt.
86
-
87
- Support of dictionaries and streaming is not planned.
88
-
89
-
90
- LINKS
91
- -----
92
-
93
- * Zstandard: https://github.com/facebook/zstd
94
- * More full-featured and compatible with Zstandard python bindings by Gregory Szorc: https://github.com/indygreg/python-zstandard
95
-
96
-
97
- Build from source
98
- -----------------
99
-
100
- >>> $ git clone https://github.com/sergey-dryabzhinsky/python-zstd
101
- >>> $ git submodule update --init
102
- >>> $ apt-get install python-dev python3-dev python-setuptools python3-setuptools
103
- >>> $ python setup.py build_ext clean
104
- >>> $ python3 setup.py build_ext clean
105
-
106
- Note: Zstd legacy format support disabled by default.
107
- To build with Zstd legacy versions support - pass ``--legacy`` option to setup.py script:
108
-
109
- >>> $ python setup.py build_ext --legacy clean
110
-
111
- When using a PEP 517 builder you can use ``ZSTD_LEGACY`` environment variable instead:
112
-
113
- >>> $ ZSTD_LEGACY=1 python -m build -w
114
-
115
- Note: Python-Zstd legacy format support removed since 1.5.0.
116
- If you need to convert old data - checkout 1.4.9.1 module version. Support of it disabled by default.
117
- To build with python-zstd legacy format support (pre 1.1.2) - pass ``--pyzstd-legacy`` option to setup.py script:
118
-
119
- >>> $ python setup.py build_ext --pyzstd-legacy clean
120
-
121
- But beware! Legacy formats support state is unknown in this case.
122
- And if your version not equal with python-zstd - tests may not pass.
123
-
124
- If you're scared of threads you may pass option `--libzstd-no-threads`:
125
-
126
- >>> $ python setup.py build_ext --libzstd-no-threads clean
127
-
128
- When using a PEP 517 builder you can use ``ZSTD_THREADS`` environment variable instead:
129
-
130
- >>> $ ZSTD_THREADS=0 python -m build -w
131
-
132
- If you're meet some cpu instruction errorrs you may try to disable built-in optimizations and pass option `--libzstd-no-use-asm`:
133
-
134
- >>> $ python setup.py build_ext --libzstd-no-use-asm clean
135
-
136
- Or add more speed with option `--libzstd-use-asm-bmi2` to use instructions for new AMD CPU.
137
- When using a PEP 517 builder you can use ``ZSTD_ASM`` environment variable instead:
138
- And ``ZST_ASM_BMI2=1`` too for bmi2 use.
139
-
140
- >>> $ ZSTD_ASM=0 python -m build -w
141
-
142
-
143
- If you want to build with existing distribution of libzstd just add ``--external`` option
144
-
145
- >>> $ python setup.py build_ext --external clean
146
-
147
- When using a PEP 517 builder you can use ``ZSTD_EXTERNAL`` environment variable instead:
148
-
149
- >>> $ ZSTD_EXTERNAL=1 python -m build -w
150
-
151
- If paths to header file ``zstd.h`` and libraries is uncommon - use common ``build`` params:
152
- --libraries --include-dirs --library-dirs.
153
-
154
- >>> $ python setup.py build_ext --external --include-dirs /opt/zstd/usr/include --libraries zstd --library-dirs /opt/zstd/lib clean
155
-
156
-
157
- Install from pypi
158
- -----------------
159
-
160
- >>> # for Python 2.7+
161
- >>> $ pip install zstd
162
- >>> # or for Python 3.4+
163
- >>> $ pip3 install zstd
164
-
165
-
166
- API
167
- ___
168
-
169
- Error
170
- Standard python Exception for zstd module
171
-
172
- ZSTD_compress (data[, level, threads]): string|bytes
173
- Function, compress input data block via mutliple threads, return compressed block, or raises Error.
174
-
175
- Params:
176
-
177
- * **data**: string|bytes - input data block, length limited by 2Gb by Python API
178
- * **level**: int - compression level, ultra-fast levels from -100 (ultra) to -1 (fast) available since zstd-1.3.4, and from 1 (fast) to 22 (slowest), 0 or unset - means default (3). Default - 3.
179
- * **threads**: int - how many threads to use, from 0 to 200, 0 or unset - auto-tune by cpu cores count. Default - 0. Since: 1.4.4.1
180
-
181
- Aliases:
182
- - *compress(...)*,
183
- - *dumps(...)*,
184
- - *encode(...)* since: 1.5.6.2
185
-
186
- Exception if:
187
- - level bigger than max level
188
-
189
- Max number of threads:
190
- - 32bit system: 64
191
- - 64bit system: 256
192
- If provided bigger number - silently set maximber (since 1.5.4.1)
193
-
194
- Since: 0.1
195
-
196
- ZSTD_uncompress (data): string|bytes
197
- Function, decompress input compressed data block, return decompressed block, or raises Error.
198
-
199
- Support compressed data with multiple/concatenated frames (blocks) (since 1.5.5.1).
200
-
201
- Params:
202
-
203
- * **data**: string|bytes - input compressed data block, length limited by 2Gb by Python API
204
-
205
- Aliases:
206
- - *decompress(...)*,
207
- - *uncompress(...)*,
208
- - *loads(...)*,
209
- - *decode(...)* since: 1.5.6.2
210
-
211
- Since: 0.1
212
-
213
- ZSTD_check (data): string|bytes
214
- Function, checks if input is zstd compressed data block, return s1if yes, 0 if no, or raises Error.
215
-
216
- Support compressed data with multiple/concatenated frames (blocks) .
217
-
218
- Params:
219
-
220
- * **data**: string|bytes - input compressed data block, length limited by 2Gb by Python API
221
-
222
- Aliases:
223
- - *check(...)*,
224
-
225
- Since: 1.5.6.2
226
-
227
- version (): string|bytes
228
- Returns this module doted version string.
229
-
230
- The first three digits are folow libzstd version.
231
- Fourth digit - module release number for that version.
232
-
233
- Since: 1.3.4.3
234
-
235
- ZSTD_version (): string|bytes
236
- Returns ZSTD library doted version string.
237
-
238
- Since: 1.3.4.3
239
-
240
- ZSTD_version_number (): int
241
- Returns ZSTD library version in format: MAJOR*100*100 + MINOR*100 + RELEASE.
242
-
243
- Since: 1.3.4.3
244
-
245
- ZSTD_threads_count (): int
246
- Returns ZSTD determined CPU cores count.
247
-
248
- Since: 1.5.4.1
249
-
250
- ZSTD_max_threads_count (): int
251
- Returns ZSTD library determined maximum working threads count.
252
-
253
- Since: 1.5.4.1
254
-
255
- ZSTD_external (): int
256
- Returns 0 of 1 if ZSTD library build as external.
257
-
258
- Since: 1.5.0.2
259
-
260
- ZSTD_with_threads (): int
261
- Returns 0 of 1 if bundled ZSTD library build with threads support.
262
-
263
- Since: 1.5.6.2
264
-
265
- ZSTD_with_asm (): int
266
- Returns 0 of 1 if bundled ZSTD library build with asm optimization s.
267
-
268
- Since: 1.5.6.2
269
-
270
-
271
- Removed
272
- _______
273
-
274
- ZSTD_compress_old (data[, level]): string|bytes
275
- Function, compress input data block, return compressed block, or raises Error.
276
-
277
- **DEPRECATED**: Returns not compatible with ZSTD block header
278
-
279
- **REMOVED**: since 1.5.0
280
-
281
- Params:
282
-
283
- * **data**: string|bytes - input data block, length limited by 2Gb by Python API
284
- * **level**: int - compression level, ultra-fast levels from -5 (ultra) to -1 (fast) available since zstd-1.3.4, and from 1 (fast) to 22 (slowest), 0 or unset - means default (3). Default - 3.
285
-
286
- Since: 1.0.0.99.1
287
-
288
- ZSTD_uncompress_old (data): string|bytes
289
- Function, decompress input compressed data block, return decompressed block, or raises Error.
290
-
291
- **DEPRECATED**: Accepts data with not compatible with ZSTD block header
292
-
293
- **REMOVED**: since 1.5.0
294
-
295
- Params:
296
-
297
- * **data**: string|bytes - input compressed data block, length limited by 2Gb by Python API
298
-
299
- Since: 1.0.0.99.1
300
-
301
- Use
302
- ___
303
-
304
- Module has simple API:
305
-
306
- >>> import zstd
307
- >>> dir(zstd)
308
- ['Error', 'ZSTD_compress', 'ZSTD_external', 'ZSTD_uncompress', 'ZSTD_version', 'ZSTD_version_number', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'compress', 'decompress', 'dumps', 'loads', 'uncompress', 'version']
309
- >>> zstd.version()
310
- '1.5.1.0'
311
- >>> zstd.ZSTD_version()
312
- '1.5.1'
313
- >>> zstd.ZSTD_version_number()
314
- 10501
315
- >>> zstd.ZSTD_external()
316
- 0
317
-
318
- In python2
319
-
320
- >>> data = "123456qwert"
321
-
322
- In python3 use bytes
323
-
324
- >>> data = b"123456qwert"
325
-
326
-
327
- >>> cdata = zstd.compress(data, 1)
328
- >>> data == zstd.decompress(cdata)
329
- True
330
- >>> cdata_mt = zstd.compress(data, 1, 4)
331
- >>> cdata == cdata_mt
332
- True
333
- >>> data == zstd.decompress(cdata_mt)
334
- True
@@ -1,6 +0,0 @@
1
- zstd.pypy38-pp73-darwin.so,sha256=GVcg3c02zJyxyfv_4gf2wCQ_8R4IngeQVTIgor-Fv00,515032
2
- zstd-1.5.6.2.dist-info/RECORD,,
3
- zstd-1.5.6.2.dist-info/LICENSE,sha256=uFlI3LUItL6HHwW5JwyqwrihDxfV2LORnmQkAhy3b-8,1320
4
- zstd-1.5.6.2.dist-info/WHEEL,sha256=rOp4SUWva7g42_KOrKAoa56qNv-f3p59x93LQqDJdXU,114
5
- zstd-1.5.6.2.dist-info/top_level.txt,sha256=DhQX04hbm3dWgbCywpue8ejkkSuxZjpZGkVlo8ca-jM,5
6
- zstd-1.5.6.2.dist-info/METADATA,sha256=Np0BcnbQ-SKcHCAhkN2HDtQ3X36SYybj9DNN8oWR8dM,10384
File without changes