Skip to content

Commit d4088c0

Browse files
authored
Move to PEP 518 build setup (#191)
Move to the new PEP 518 build setup that uses read only metadata and the new pyproject.toml configuration file. This should have no affect on end users of this library as Python has supported this configuration format in all the currently supported Python versions.
1 parent 572de55 commit d4088c0

File tree

7 files changed

+51
-75
lines changed

7 files changed

+51
-75
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,6 @@ jobs:
2929
fail-fast: false
3030
matrix:
3131
include:
32-
- python-version: '3.6'
33-
image: python:3.6-slim
34-
- python-version: '3.7'
35-
image: python:3.7-slim
3632
- python-version: '3.8'
3733
image: python:3.8-slim
3834
- python-version: '3.9'
@@ -72,14 +68,13 @@ jobs:
7268

7369
- name: Set up Python
7470
uses: actions/setup-python@v5
75-
76-
- name: Installing baseline packages
77-
run: |
78-
echo "Installing baseline pip packages"
79-
python -m pip install --upgrade pip setuptools wheel
71+
with:
72+
python-version: '3.12'
8073

8174
- name: Build package
82-
run: python setup.py sdist bdist_wheel
75+
run: |
76+
python -m pip install build
77+
python -m build
8378
8479
- name: Capture Wheel and SDist
8580
uses: actions/upload-artifact@v4

HISTORY.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
History
22
=======
33

4+
0.16.0: TBD
5+
-----------
6+
7+
- Raised minimum Python version to 3.8
8+
- Changed project build metadata to use PEP 518 pyproject.toml
9+
410
0.15.0: 2024-06-04
511
------------------
612

ci/setup-kerb.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,6 @@ else
150150
fi
151151

152152
echo "Updating pip and installing library"
153-
pip$PY_MAJOR install -U pip setuptools
154153
pip$PY_MAJOR install .
155154
pip$PY_MAJOR install -r requirements-test.txt
156155

pyproject.toml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
[build-system]
2+
requires = [
3+
"setuptools >= 61.0.0", # Support for setuptools config in pyproject.toml
4+
]
5+
build-backend = "setuptools.build_meta"
6+
7+
[project]
8+
name = "requests-kerberos"
9+
description = "A Kerberos authentication handler for python-requests"
10+
requires-python = ">=3.8"
11+
license = { file = "LICENSE" }
12+
authors = [
13+
{ name = "Ian Cordasco", email = "[email protected]" },
14+
{ name = "Cory Benfield" },
15+
{ name = "Michael Komitee'" }
16+
]
17+
classifiers = [
18+
"License :: OSI Approved :: ISC License (ISCL)"
19+
]
20+
dependencies = [
21+
"requests >= 1.1.0",
22+
"cryptography >= 1.3",
23+
"pyspnego[kerberos]"
24+
]
25+
dynamic = ["version", "readme"]
26+
27+
[project.urls]
28+
homepage = "https://github.com/requests/requests-kerberos"
29+
30+
[tool.setuptools]
31+
include-package-data = true
32+
packages = ["requests_kerberos"]
33+
34+
[tool.setuptools.package-data]
35+
"*" = ["LICENSE", "AUTHORS"]
36+
37+
[tool.setuptools.dynamic]
38+
version = { attr = "requests_kerberos.__version__" }
39+
readme = { file = ["README.rst", "HISTORY.rst"], content-type = "text/x-rst" }

requests_kerberos/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@
2121

2222
__all__ = ('HTTPKerberosAuth', 'MutualAuthenticationError', 'REQUIRED',
2323
'OPTIONAL', 'DISABLED')
24-
__version__ = '0.15.0'
24+
__version__ = '0.16.0'

setup.cfg

Lines changed: 0 additions & 2 deletions
This file was deleted.

setup.py

Lines changed: 0 additions & 61 deletions
This file was deleted.

0 commit comments

Comments
 (0)