Skip to content

Commit

Permalink
add support for python 3.13
Browse files Browse the repository at this point in the history
  • Loading branch information
ahupp committed Feb 19, 2025
1 parent a3ed086 commit 7583e44
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 31 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ jobs:
strategy:
fail-fast: false
matrix:
os: ['ubuntu-latest']
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
os: ["ubuntu-latest"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
include:
- os: macos-latest
python-version: '3.13'
python-version: "3.13"
# - os: windows-latest # TODO: Fix the Windows test that runs in an infinite loop
# python-version: '3.13'
runs-on: ${{ matrix.os }}
Expand All @@ -28,4 +28,4 @@ jobs:
run: pip install python-magic-bin
- run: LC_ALL=en_US.UTF-8 pytest
shell: bash
timeout-minutes: 15 # Limit Windows infinite loop.
timeout-minutes: 15 # Limit Windows infinite loop.
56 changes: 29 additions & 27 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,41 +8,43 @@

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


setuptools.setup(
name='python-magic',
description='File type identification using libmagic',
author='Adam Hupp',
author_email='[email protected]',
name="python-magic",
description="File type identification using libmagic",
author="Adam Hupp",
author_email="[email protected]",
url="http://github.com/ahupp/python-magic",
version='0.4.28',
long_description=read('README.md'),
long_description_content_type='text/markdown',
packages=['magic'],
version="0.4.28",
long_description=read("README.md"),
long_description_content_type="text/markdown",
packages=["magic"],
package_data={
'magic': ['py.typed', '*.pyi', '**/*.pyi'],
"magic": ["py.typed", "*.pyi", "**/*.pyi"],
},
keywords="mime magic file",
license="MIT",
python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*',
python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
classifiers=[
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'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',
'Programming Language :: Python :: Implementation :: CPython',
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"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",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: CPython",
],
)

1 change: 1 addition & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ envlist =
py310,
py311,
py312,
py313,
mypy

[testenv]
Expand Down

0 comments on commit 7583e44

Please sign in to comment.