Skip to content

Commit 9bf878d

Browse files
committed
Merge remote-tracking branch 'origin/main' into lz4
2 parents ea4d533 + d1931cb commit 9bf878d

5 files changed

Lines changed: 25 additions & 8 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
strategy:
3535
matrix:
3636
os: [ubuntu-latest]
37-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "pypy-3.9"]
37+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "pypy-3.9"]
3838
optional-deps: [true]
3939
with-libs: [true]
4040
include:

README.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ Supported compression formats are:
2929
- lz4 (``.lz4``)
3030
- Zstandard (``.zst``) (optional)
3131

32-
``xopen`` is compatible with Python versions 3.8 and later.
33-
3432

3533
Example usage
3634
-------------
@@ -188,6 +186,12 @@ To ensure that you get the correct ``zstandard`` version, you can specify the ``
188186
Changelog
189187
---------
190188

189+
development version
190+
~~~~~~~~~~~~~~~~~~~
191+
192+
* Dropped support for Python 3.8
193+
* Started supporting Python 3.13
194+
191195
v2.0.2 (2024-06-12)
192196
~~~~~~~~~~~~~~~~~~~
193197
* #161: Fix a bug that was triggered when reading large compressed files with

pyproject.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[build-system]
2-
requires = ["setuptools", "setuptools_scm[toml]>=6.2"]
2+
requires = ["setuptools >= 77.0.3", "setuptools_scm[toml]>=6.2"]
33
build-backend = "setuptools.build_meta"
44

55
[project]
@@ -10,13 +10,12 @@ authors = [
1010
]
1111
description = "Open compressed files transparently"
1212
readme = "README.rst"
13-
license = {text = "MIT"}
13+
license = "MIT"
1414
classifiers = [
1515
"Development Status :: 5 - Production/Stable",
16-
"License :: OSI Approved :: MIT License",
1716
"Programming Language :: Python :: 3"
1817
]
19-
requires-python = ">=3.8"
18+
requires-python = ">=3.9"
2019
dynamic = ["version"]
2120
dependencies = [
2221
'isal>=1.6.1; platform.machine == "x86_64" or platform.machine == "AMD64" or platform.machine == "aarch64"',

tests/test_xopen.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,20 @@ def test_bare_read_from_gz():
349349
assert f.read() == "hello"
350350

351351

352+
@pytest.mark.parametrize("threads", [None, 0, 2])
353+
def test_concatenated_gzip(tmp_path, threads):
354+
path = tmp_path / "hello.gz"
355+
with gzip.open(path, mode="wt") as f:
356+
print("Hello", file=f)
357+
with gzip.open(path, mode="at") as f:
358+
print("world", file=f)
359+
360+
with xopen(path, threads=threads) as f:
361+
lines = list(f)
362+
363+
assert lines == ["Hello\n", "world\n"]
364+
365+
352366
def test_read_no_threads(ext):
353367
klasses = {
354368
".bz2": bz2.BZ2File,

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[tox]
2-
envlist = black,flake8,mypy,py38,py39,py310,py311,py312,pypy3
2+
envlist = black,flake8,mypy,py39,py310,py311,py312,py313,pypy3
33
isolated_build = True
44

55
[testenv]

0 commit comments

Comments
 (0)