Skip to content

Commit 7583e44

Browse files
committed
add support for python 3.13
1 parent a3ed086 commit 7583e44

File tree

3 files changed

+34
-31
lines changed

3 files changed

+34
-31
lines changed

.github/workflows/ci.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ jobs:
55
strategy:
66
fail-fast: false
77
matrix:
8-
os: ['ubuntu-latest']
9-
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
8+
os: ["ubuntu-latest"]
9+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
1010
include:
1111
- os: macos-latest
12-
python-version: '3.13'
12+
python-version: "3.13"
1313
# - os: windows-latest # TODO: Fix the Windows test that runs in an infinite loop
1414
# python-version: '3.13'
1515
runs-on: ${{ matrix.os }}
@@ -28,4 +28,4 @@ jobs:
2828
run: pip install python-magic-bin
2929
- run: LC_ALL=en_US.UTF-8 pytest
3030
shell: bash
31-
timeout-minutes: 15 # Limit Windows infinite loop.
31+
timeout-minutes: 15 # Limit Windows infinite loop.

setup.py

+29-27
Original file line numberDiff line numberDiff line change
@@ -8,41 +8,43 @@
88

99
def read(file_name):
1010
"""Read a text file and return the content as a string."""
11-
with io.open(os.path.join(os.path.dirname(__file__), file_name),
12-
encoding='utf-8') as f:
11+
with io.open(
12+
os.path.join(os.path.dirname(__file__), file_name), encoding="utf-8"
13+
) as f:
1314
return f.read()
1415

16+
1517
setuptools.setup(
16-
name='python-magic',
17-
description='File type identification using libmagic',
18-
author='Adam Hupp',
19-
author_email='[email protected]',
18+
name="python-magic",
19+
description="File type identification using libmagic",
20+
author="Adam Hupp",
21+
author_email="[email protected]",
2022
url="http://github.com/ahupp/python-magic",
21-
version='0.4.28',
22-
long_description=read('README.md'),
23-
long_description_content_type='text/markdown',
24-
packages=['magic'],
23+
version="0.4.28",
24+
long_description=read("README.md"),
25+
long_description_content_type="text/markdown",
26+
packages=["magic"],
2527
package_data={
26-
'magic': ['py.typed', '*.pyi', '**/*.pyi'],
28+
"magic": ["py.typed", "*.pyi", "**/*.pyi"],
2729
},
2830
keywords="mime magic file",
2931
license="MIT",
30-
python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*',
32+
python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
3133
classifiers=[
32-
'Intended Audience :: Developers',
33-
'License :: OSI Approved :: MIT License',
34-
'Programming Language :: Python',
35-
'Programming Language :: Python :: 2.7',
36-
'Programming Language :: Python :: 3',
37-
'Programming Language :: Python :: 3.5',
38-
'Programming Language :: Python :: 3.6',
39-
'Programming Language :: Python :: 3.7',
40-
'Programming Language :: Python :: 3.8',
41-
'Programming Language :: Python :: 3.9',
42-
'Programming Language :: Python :: 3.10',
43-
'Programming Language :: Python :: 3.11',
44-
'Programming Language :: Python :: 3.12',
45-
'Programming Language :: Python :: Implementation :: CPython',
34+
"Intended Audience :: Developers",
35+
"License :: OSI Approved :: MIT License",
36+
"Programming Language :: Python",
37+
"Programming Language :: Python :: 2.7",
38+
"Programming Language :: Python :: 3",
39+
"Programming Language :: Python :: 3.5",
40+
"Programming Language :: Python :: 3.6",
41+
"Programming Language :: Python :: 3.7",
42+
"Programming Language :: Python :: 3.8",
43+
"Programming Language :: Python :: 3.9",
44+
"Programming Language :: Python :: 3.10",
45+
"Programming Language :: Python :: 3.11",
46+
"Programming Language :: Python :: 3.12",
47+
"Programming Language :: Python :: 3.13",
48+
"Programming Language :: Python :: Implementation :: CPython",
4649
],
4750
)
48-

tox.ini

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ envlist =
99
py310,
1010
py311,
1111
py312,
12+
py313,
1213
mypy
1314

1415
[testenv]

0 commit comments

Comments
 (0)