Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Libbrotli 1.1.0 #194

Merged
merged 5 commits into from
Sep 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 8 additions & 22 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- name: Set git to use LF on Windows
if: runner.os == 'Windows'
Expand All @@ -31,26 +32,11 @@ jobs:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: actions/setup-python@v1
if: runner.os != 'Windows' # see issue #174
with:
python-version: 2.7
- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: 3.5
- uses: actions/setup-python@v1
with:
python-version: 3.9
# - name: Install Visual C++ for Python 2.7
# if: runner.os == 'Windows'
# run: choco install vcpython27 -f -y
- name: Run tests on Windows # see issue #174
if: runner.os == 'Windows'
run: |
python -m pip install tox
tox -e py35,py39
- name: Run tests on Linux and macOS
if: runner.os != 'Windows'
python-version: ${{ matrix.python-version }}
allow-prereleases: true
- name: Run tests
run: |
python -m pip install tox
tox --skip-missing-interpreters
Expand All @@ -63,7 +49,7 @@ jobs:
submodules: recursive
- uses: actions/setup-python@v1
with:
python-version: 3.8
python-version: 3.x
- name: Build source package
run: python setup.py sdist
- name: Upload source package
Expand Down Expand Up @@ -105,13 +91,13 @@ jobs:
if: runner.os == 'Windows'
run: python -m cibuildwheel --output-dir wheelhouse
env:
CIBW_BUILD: cp35-${{ matrix.name }}* pp*-${{ matrix.name }}*
CIBW_BUILD: cp37-${{ matrix.name }}* pp*-${{ matrix.name }}*

- name: Build wheels for Linux and macOS
if: runner.os != 'Windows'
run: python -m cibuildwheel --output-dir wheelhouse
env:
CIBW_BUILD: cp27-${{ matrix.name }}* cp35-${{ matrix.name }}* pp*-${{ matrix.name }}*
CIBW_BUILD: cp37-${{ matrix.name }}* pp*-${{ matrix.name }}*
CIBW_ARCHS_LINUX: auto aarch64
CIBW_BEFORE_BUILD_LINUX: yum install -y libffi-devel
- uses: actions/upload-artifact@v2
Expand Down
8 changes: 8 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
Changelog
=========

1.1.0.0 (2023-09-14)
--------------------

- Upgraded libbrotli to v1.1.0
- Added explicit support for Python 3.10, 3.11, and 3.12
- Removed support for Python 2.7, 3.5, and 3.6


1.0.9.2 (2021-04-06)
--------------------

Expand Down
5 changes: 0 additions & 5 deletions Makefile

This file was deleted.

2 changes: 1 addition & 1 deletion libbrotli
Submodule libbrotli updated 236 files
3 changes: 2 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ markers =
slow: marks tests as slow (deselect with '-m "not slow"')

[metadata]
license_file = LICENSE
license_files =
LICENSE
11 changes: 4 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ def finalize_options(self):
],
install_requires=[
"cffi>=1.0.0",
"enum34;python_version<'3.4'",
],
python_requires=">=3.7",
cffi_modules=["src/brotlicffi/_build.py:ffi"],
packages=find_packages('src'),
package_dir={'': 'src'},
Expand All @@ -112,15 +112,12 @@ def finalize_options(self):
classifiers=[
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
)
2 changes: 1 addition & 1 deletion src/brotlicffi/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
Compressor, MODE_GENERIC, MODE_TEXT, MODE_FONT, error, Error
)

__version__ = "1.0.9.2"
__version__ = "1.1.0.0"
19 changes: 10 additions & 9 deletions test/test_compatibility.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,16 @@ def test_brotli_version():
dirname(dirname(abspath(__file__))), "libbrotli/c/common/version.h"
)
with open(version_h) as f:
brotli_version = int(
re.search(
r"#define BROTLI_VERSION 0x([A-Fa-f0-9]+)", f.read()
).group(1),
16,
brotli_versions = dict(
re.findall(
r"#define BROTLI_VERSION_(MAJOR|MINOR|PATCH) ([0-9]+)",
f.read()
)
)
major = brotli_version >> 24
minor = (brotli_version >> 12) & 0xFFF
patch = brotli_version & 0xFFF
assert brotlicffi.__version__.startswith(
"%d.%d.%d." % (major, minor, patch)
"%s.%s.%s." % (
brotli_versions["MAJOR"],
brotli_versions["MINOR"],
brotli_versions["PATCH"]
)
)
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py27, py34, py35, py36, py37, py38, py39, pypy, lint
envlist = py37, py38, py39, py310, py311, py312, pypy, lint

[testenv]
deps= -r{toxinidir}/test_requirements.txt
Expand Down
Loading