kc3-lang/brotli/python

Branch :


Log

Author Commit Date CI Message
ed93810e 2025-10-02 01:50:29 support multi-phase initialization PiperOrigin-RevId: 814128632
1f6ab76b 2025-09-29 05:11:53 use module-bound exception PiperOrigin-RevId: 812739918
14068984 2025-09-25 07:59:41 Build and test with PY2.7 PiperOrigin-RevId: 811352084
9686382f 2025-09-24 03:52:03 PY: continue renovation of extension Fixed unchecked malloc for "tail" input data. Fixed inconsistencies in docstrings. Rewritten "growable buffer" to C-code, so it could run without acquiring GIL. Breaking changes: - native object allocation failures now handled at object creation time - some lower level exceptions (e.g. OOM) are not shadowed by brotli.error PiperOrigin-RevId: 810813664
41a22f07 2025-09-08 09:15:12 modernize PY3 class definition PiperOrigin-RevId: 804460135
98a89b15 2025-09-05 07:57:28 temporary rollback PiperOrigin-RevId: 803462595
35d4992a 2025-09-05 04:41:26 PY: reformat _brotli.c PiperOrigin-RevId: 803412055
79ea7296 2025-08-29 15:06:37 Merge branch 'master' into master
9a4ba593 2025-08-15 06:18:13 internal change PiperOrigin-RevId: 795452145
964ca075 2025-06-13 14:57:19 fix module import in set exception + setup.py compatible with python2
ddb803ac 2025-06-13 14:13:12 using static function
998a28bd 2025-06-13 14:09:51 using module state for error handling
dcc24d05 2025-05-28 14:13:46 chore: fixing trailing whitespace in python/README.md
9b7beb42 2025-05-27 08:06:30 Merge branch 'google:master' into master
3487b691 2025-05-27 09:37:03 Update bro.py: Fix undefined name in Python code (#1240) `outfile` is used before it is defined on the following line so use `options.outfile` instead. % `ruff check` ``` Error: python/bro.py:168:64: F821 Undefined name `outfile` ``` Co-authored-by: Eugene Kliuchnikov <eustas.ru@gmail.com>
e45f18cc 2025-03-15 11:23:32 DECREF on exception raise
c710db05 2025-03-15 09:13:46 enabled support to 3.12 per GIL interpeter using multistage module inizialization
eb3a31e2 2024-09-18 15:25:06 add max_length to Python streaming decompression
28ce91ca 2024-09-17 16:50:39 add size limit to buffer
d019271c 2025-01-06 03:05:20 Copybara import of the project: -- f1bdfaa803e62ce3608e0226c98da1cf20abebdc by Robert Obryk <robryk@google.com>: add size limit to buffer -- ef8922cee72a1c0b0c35ed109ae9d2d637177bfe by Robert Obryk <robryk@google.com>: add max_length to Python streaming decompression PiperOrigin-RevId: 712463460
ef9e12f0 2025-01-06 02:37:01 Merge pull request #1201 from robryk:sizelimit PiperOrigin-RevId: 712456783
ef8922ce 2024-09-18 15:25:06 add max_length to Python streaming decompression
3a444a6f 2024-11-21 12:26:45 Merge branch 'google:master' into master
2dfaadce 2024-11-19 08:14:51 (PY) clarify compressor mode parameter values PiperOrigin-RevId: 698023020
f1bdfaa8 2024-09-17 16:50:39 add size limit to buffer
2a01fd8f 2024-07-29 20:05:34 + Added ability to build Brotli Python bindings against system-provided brotli instead of vendored one
acc26565 2023-07-19 05:43:51 Small Python modernization of Brotli code. PiperOrigin-RevId: 549289787
bc32ae12 2023-07-04 13:01:14 add tests with UTF8/UTF16 non-ASCII text PiperOrigin-RevId: 545424981
38e9add9 2023-01-31 21:28:34 Fix permissions PiperOrigin-RevId: 506096478
36533a86 2023-01-16 18:04:35 Internal change PiperOrigin-RevId: 502401179
c8df4b30 2022-12-29 21:07:16 Python: use a new output buffer code (#902) Currently, the output buffer is a std::vector<uint8_t>. When the buffer grows, resizing will cause unnecessary memcpy(). This change uses a list of bytes object to represent output buffer, can avoid the extra overhead of resizing. In addition, C++ code can be removed, it's a pure C extension.
a8f5813b 2022-11-17 13:03:09 Update Documentation: - add note that brotli is a "stream" format, not an archive-like - regenerate .1 with Pandoc Build: - drop legacy "BROTLI_BUILD_PORTABLE" option - drop "BROTLI_SANITIZED" definition Code: - c: comb includes - c/enc: extract encoder state into separate header - c/enc: drop designated q10 codepath - c/enc: dealing better with flushing of empty stream - fix MSVC compilation API: - py: use library version instead of one in version.h - c: add plugable API to report consumed input / produced output - c/java: support "lean" prepared dictionaries (without copy of source)
8376f72e 2021-11-10 10:34:39 Prepare for copybara (#939) Co-authored-by: Eugene Kliuchnikov <eustas@chromium.org>
68f1b90a 2021-08-18 19:15:07 Update (#918) Prepare to use copybara worklow.
7f740f13 2020-05-15 11:06:21 Update (#807) - fix formatting - fix type conversion - fix no-op arithmetic with null-pointer - improve performance of hash_longest_match64 - go: detect read after close - java decoder: support compound dictionary - remove executable flag on non-scripts
c8b37e8f 2019-07-17 14:39:56 Update (#762) * put LICENSE file into .jar * fix typo * add clarification comment in PY wrapper
5805f99a 2018-11-12 04:36:00 Ensure decompression consumes all input (#730) * Ensure decompression consumes all input If not, it's a corrupt stream. * Use byte strings
2c034825 2018-03-23 02:09:00 Fix "memory leak" in python tests (#652) OOMs on RPi (1GB)
a629289e 2017-08-28 11:31:29 Update (#590) * add transpiled JS decoder * make PY wrapper accept memview * fix dictionary generator * speedup compression of RLEish data
4f455cac 2017-08-23 19:45:13 disable buidling/deployment of python wheels (#583) * [appveyor] remove 'deploy' stage; only test python 2.7 and 3.6 all the other python versions are being built and tested on https://github.com/google/brotli-wheels/blob/d571d63/appveyor.yml * remove terrify submodule as not needed any more * [travis] just test py2.7 and 3.6 on linux; remove extra osx python builds All the other python versions for OSX are being built/tested on: https://github.com/google/brotli-wheels/blob/d571d63/.travis.yml Also, there's no need to build and deploy wheels here, as that's done in the separate repository. * [setup.py] only rebuild if dependency are newer; fix typo in list of 'depends' https://github.com/python/cpython/blob/v3.6.2/Lib/distutils/command/build_ext.py#L485-L500 * [ci] only run 'python setup.py test' if we run 'python setup.py built test', the setuptools 'test' command will forcibly re-run the build_ext subcommand because it wants to pass the --inplace option (it ignores whether it's up to date, just re-runs it all the time). with this we go from running built_ext twice, to running it only once per build * [Makefile] run 'build_ext --inplace' instead of 'develop' as default target The 'develop' command is like 'install' in the sense that it modifies the user's python environment. The default make target should be less intrusive, i.e. just building the extension module in-place without modify anything in the user's environment. We don't need to tell make about the dependency between 'test' and 'build' target as that is baked in the `python setup.py test` command. * [Makefile] add 'develop' target; remove unnecessary 'tests' target `make test` is good enough * [Makefile] `setup.py test` requires setuptools; run `python -m unittest` This will work even if setuptools is not installed, which is unlikely nowadays but still our `setup.py` works with plain distutils, so we may well have our tests work without setuptools. * [python/README.md] add ref to 'develop' target; remove 'tests', just 'make test' * [setup.py] import modules as per nicksay's comment https://github.com/google/brotli/pull/583#discussion_r131981049 * [Makefile] add 'develop' to .PHONY targets remove 'tests' from .PHONY * [appveyor] remove unused setup scripts We don't need to install custom python versions, we are using the pre-installed ones on Appveyor. * [appveyor] remove unneeded setup code
019091f9 2017-08-08 04:25:39 Python: Update bro_test to reference script directly (#582)
d63e8f75 2017-08-04 10:02:56 Update API, and more (#581) Update API, and more: * remove "custom dictionary" support * c/encoder: fix #580: big-endian build * Java: reduce jar size * Java: speedup decoding * Java: add 32-bit CPU support * Java: make source code JS transpiler-ready
06082531 2017-08-02 10:59:46 Python: Add a "make install" command and clarify installation docs (#578) Closes #576
52441069 2017-07-21 10:07:24 Update (#574) * Update * decoder: better behavior after failure * encoder: replace "len_x_code" with delta * research: add experimental dictionary generator * python: test combing
1becbbf2 2017-06-30 13:09:50 Update (#569) * add misssing fclose in `brotli.c` * add basic tests for python `Decompressor` type * minor lint fixes in `_brotli.cc`
58f5c37f 2017-06-28 16:32:28 Python: Decompressor: Streaming decompression support (#546) python-brotli has Compressor for streaming compression but nothing for streaming decompression. This is a straight-forward copy of the Compressor code into the new class Decompressor.
6ab0a5ce 2016-12-21 04:17:11 Python: Create Makefile for development shortcuts (#488)
fd96151b 2016-12-20 18:00:51 Move brotlidump.py to research/ (#487)
f62cd2bc 2016-12-20 14:41:47 brotlidump.py: disassemble brotli file (revisited) (#314) * Create brotlidump.py Sorry, I am a newbie. I couldn't find my file anymore when I wanted to edit it. Hope I don't waste your time. * Fixed a bug where it couldn't read its own compression. The problem was that a prefix code ending with a 16 "repeat" didn't realize the table was full already. Also minor bug fixes, comments and stuff. * Major refactoring Rewrote almost everything. Now can dump its own compression. * Now more or less complete Appears to handle all files completely (including metablock data). Used as inspiration for the the hex example (see makehexexample.py)
89a5b6e6 2016-12-20 08:40:47 Python: Simplify test suite generation by using unittest discovery (#485)
6f227228 2016-12-12 04:28:44 Python: Use a temporary directory for generated files in tests (#481)
4651f7c0 2016-12-12 04:28:15 Python: Format bro.py with yapf (#480)
0ee41613 2016-12-12 10:27:13 Update python brotli wrapper (#479) * Update python brotli wrapper * release GIL on CPU intensive blocks, fixes #476 * use BrotliDecoderTakeOutput (less memory, less memcpy) * Python: Convert bro.py tests to unittest style (#478) * Create unittest-style tests for `bro.py` decompression and compression * Delete old tests for `bro.py` * Update test method generation to properly create a Cartesian product of iterables using `itertools.product` * Update python brotli wrapper * release GIL on CPU intensive blocks, fixes #476 * use BrotliDecoderTakeOutput (less memory, less memcpy)
4a60128c 2016-12-09 07:44:05 Python: Convert bro.py tests to unittest style (#478) * Create unittest-style tests for `bro.py` decompression and compression * Delete old tests for `bro.py` * Update test method generation to properly create a Cartesian product of iterables using `itertools.product`
1e5ea6ae 2016-11-09 06:21:13 Python: Add unit tests for brotli.compress and brotli.decompress (#467) Also - rename `test_utils` to `_test_utils` - refactor shared code into `_test_utils`
a260b6ba 2016-10-31 08:24:01 Python: Add tests for streamed compression (#458) Progress on #191
92037654 2016-10-31 07:58:45 Python: Use "build" instead of "build_ext" in scripts (#460) Previously, the Python package consisted of a single extension module, so `build_ext` was sufficient. Now, the package contains a native module and an extension module, so both `build_py` and `build_ext` are required. Instead, run `build`, which calls both `build_py` and `build_ext` automatically.
afb12727 2016-10-25 04:19:29 Python: Publicly expose the Compressor object in the Python API (#456) Progress on #191
5632315d 2016-10-24 07:28:56 Python: Support streamed compression with the Compressor object (#448) This adds `flush` and `finish` methods to the `Compressor` object in the extension module, renames the `compress` method to `process`, and updates that method to only process data. Now, one or more `process` calls followed by a `finish` call will be equivalent to a module-level `compress` call. Note: To maximize the compression efficiency (and match underlying Brotli behavior, the `Compressor` object `process` method does not guarantee all input is immediately written to output. To ensure immediate output, call `flush` to manually flush the compression buffer. Extraneous flushing can increase the size, but may be required when processing streaming data. Progress on #191
2d441179 2016-10-18 10:31:05 Merge pull request #446 from nicksay/py-3-compressor-object Python: Create an extension Compressor object
b04f4ea1 2016-10-17 13:00:14 Python: Update README with information about code formatting Also, add a `yapf` section to `setup.cfg` to ensure YAPF runs format code with the Google style.
595a5246 2016-09-29 15:14:16 Python: Create an extension Compressor object - Create a `Compressor` object in the extension module - Move the `compress` method into the native module and use the new `Compressor` object to do the compression Note: This does not change the module-level Python API. The `Compressor` object will not be publicly exposed until its methods have stabilized.
f7b5b3dc 2016-09-28 17:26:00 Python: Create native brotli module and move extension to _brotli
86fdb683 2016-09-21 16:02:32 Update brotlimodule.cc
7cbdb4aa 2016-09-21 15:51:54 Update brotlimodule.cc
b754f607 2016-09-21 15:37:45 Update python module * use new decoder API
81480011 2016-08-23 14:40:33 Move "public" to "include/brotli"
2c2d5578 2016-08-22 15:44:12 Use version from common/version.h
dae9c7ff 2016-08-22 14:00:42 Fix brotlimodule
27f9d00e 2016-06-23 11:02:53 Fix issue #383
81054a46 2016-06-17 20:24:24 Restore platform suffix
f0c7ece3 2016-06-16 17:45:05 Remove platform suffix
bac060f1 2016-06-16 17:25:26 Fix library path
8872d7b4 2016-06-13 15:22:13 Fix CI build.
3ccbf05d 2016-06-13 11:01:04 Convert encoder to plain C.
55bd78fb 2016-06-03 12:31:02 Fix test file path
ab53fc31 2016-06-03 12:30:45 Fix test file path
db3a1162 2016-06-13 15:22:13 Fix CI build.
b972c677 2016-06-13 11:01:04 Convert encoder to plain C.
b73ebe32 2016-06-03 12:31:02 Fix test file path
66606e7d 2016-06-03 12:30:45 Fix test file path
bb6f5fea 2016-06-03 11:12:12 Merge pull request #336 from anthrotype/upload-sdist appveyor: also upload source distribution packages to Github Releases
75c6c1ab 2016-04-19 16:43:42 Fix brotlimodule
f66c7c54 2016-04-10 20:51:10 python/tests: clean up generated files if successful
7e5bbd5f 2016-02-24 16:54:54 Merge pull request #321 from eustas/master Add custom dictionary feature binding
7d25e6b6 2016-02-24 16:01:35 Truncate dictionary to window size.
cbb0d4cd 2016-02-23 17:45:42 Remove streaming test.
30612e3a 2016-02-23 17:42:55 Add binding for custom_dictionary.
14276922 2016-02-23 16:10:53 Fix typo
7111c339 2016-02-23 16:06:31 Create README.md
291d21cc 2016-02-19 16:54:15 Fix choices for --lgwin and --mode in python/bro.py.
c5c80a9f 2016-01-25 15:13:17 Addressed comment
8e8b8de0 2016-01-25 12:33:38 Update brotlimodule.cc
1b938dc7 2016-01-25 12:16:36 Update brotlimodule.cc
c49918e1 2016-01-25 12:07:39 Update brotlimodule.cc
ca0ae4cb 2016-01-25 11:40:20 Update brotlimodule.cc
a4f40c1b 2016-01-25 11:39:05 Fix brotlimodule compilation warnings
fec00d24 2016-01-23 00:31:47 Make input const
a22993b3 2016-01-22 14:09:25 Fix pointer dereferencing.
1f910642 2016-01-22 14:01:46 Remove deprecated API call