From ab979486c741786b421fa9493a7b4612cade1eef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Tue, 2 May 2023 22:40:41 +0200 Subject: [PATCH 01/10] Use dependabot to update GitHub actions --- .github/dependabot.yml | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..5ace4600 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" From 6ab58d4ca092ba88ae317c18db49d143635b6b45 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 May 2023 20:45:05 +0000 Subject: [PATCH 02/10] Bump actions/setup-python from 2 to 4 Bumps [actions/setup-python](https://github.com/actions/setup-python) from 2 to 4. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v2...v4) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/check.yml | 2 +- .github/workflows/docs.yml | 2 +- .github/workflows/packaging.yml | 2 +- .github/workflows/test.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 00d843e3..39110693 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -24,7 +24,7 @@ jobs: - uses: actions/checkout@v2 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 - name: Install dependencies run: python -m pip install tox diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 649299d3..ea52fab9 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v2 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 - name: Install dependencies run: python -m pip install tox diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml index 8f808632..308c6e74 100644 --- a/.github/workflows/packaging.yml +++ b/.github/workflows/packaging.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v2 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 - name: Install dependencies run: python -m pip install tox diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index df8e4143..a9d35806 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -53,7 +53,7 @@ jobs: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} From 827bf49cf2bf53ee45ab557a383486895a70ad93 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 May 2023 20:51:31 +0000 Subject: [PATCH 03/10] Bump actions/checkout from 2 to 3 Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v2...v3) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/check.yml | 2 +- .github/workflows/docs.yml | 2 +- .github/workflows/packaging.yml | 2 +- .github/workflows/test.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 39110693..db760ebf 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -21,7 +21,7 @@ jobs: TOXENV: ${{ matrix.tox-environment }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python uses: actions/setup-python@v4 diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index ea52fab9..9830a524 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -22,7 +22,7 @@ jobs: sudo apt-get install apparmor-utils sudo aa-disable /usr/sbin/slapd - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python uses: actions/setup-python@v4 diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml index 308c6e74..4e3d2e77 100644 --- a/.github/workflows/packaging.yml +++ b/.github/workflows/packaging.yml @@ -22,7 +22,7 @@ jobs: sudo apt-get install apparmor-utils sudo aa-disable /usr/sbin/slapd - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python uses: actions/setup-python@v4 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a9d35806..e2618178 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -50,7 +50,7 @@ jobs: sudo apt-get install apparmor-utils sudo aa-disable /usr/sbin/slapd - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v4 From 60733536d12df9c92a8272c4c176edd8f12c324e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Tue, 2 May 2023 23:02:11 +0200 Subject: [PATCH 04/10] Remove package= from setup.cfg The package is unnecessary, setuptools_scm knows what files to package from source control. --- setup.cfg | 1 - 1 file changed, 1 deletion(-) diff --git a/setup.cfg b/setup.cfg index 68aa559d..0afa1eb5 100644 --- a/setup.cfg +++ b/setup.cfg @@ -36,7 +36,6 @@ project_urls = [options] python_requires = >=3.7 -packages = django_auth_ldap install_requires = Django>=3.2 python-ldap>=3.1 From d3a6ef63bf919310b729600cfdbdbf4d0c13fb85 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Wed, 7 Jun 2023 09:42:16 +0200 Subject: [PATCH 05/10] Update tox envlist --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index d24e399a..b003b3a9 100644 --- a/tox.ini +++ b/tox.ini @@ -5,8 +5,8 @@ envlist = isort docs django32 - django40 django41 + django42 djangomain isolated_build = true From d00222511379151d1499fc9e57af2abcd998028b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Sat, 13 May 2023 20:33:02 +0200 Subject: [PATCH 06/10] Switch to pyproject.toml --- pyproject.toml | 51 ++++++++++++++++++++++++++++++++++++++++++++++++++ setup.cfg | 45 -------------------------------------------- 2 files changed, 51 insertions(+), 45 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index b749ea1d..9db6fb26 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,54 @@ +[project] +name = "django-auth-ldap" +requires-python = ">=3.7" +description = "Django LDAP authentication backend" +readme = "README.rst" +authors = [ + { name="Peter Sagerson", email="psagers@ignorare.net"}, +] +maintainers = [ + { name="François Freitag", email="mail@franek.fr" }, +] +license = { text="BSD" } +classifiers = [ + "Development Status :: 5 - Production/Stable", + "Environment :: Web Environment", + "Framework :: Django", + "Framework :: Django :: 3.2", + "Framework :: Django :: 4.1", + "Framework :: Django :: 4.2", + "Intended Audience :: Developers", + "Intended Audience :: System Administrators", + "License :: OSI Approved :: BSD License", + "Programming Language :: Python", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3 :: Only", + "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", + "Topic :: Internet :: WWW/HTTP", + "Topic :: Software Development :: Libraries :: Python Modules", + "Topic :: System :: Systems Administration :: Authentication/Directory :: LDAP", +] +dynamic = ["version"] + +dependencies = [ + "Django>=3.2", + "python-ldap>=3.1", +] + +[project.urls] +Homepage = "https://github.com/django-auth-ldap/django-auth-ldap" +Documentation = "https://django-auth-ldap.readthedocs.io/" +Source = "https://github.com/django-auth-ldap/django-auth-ldap" +Tracker = "https://github.com/django-auth-ldap/django-auth-ldap/issues" +Changelog = "https://github.com/django-auth-ldap/django-auth-ldap/releases/" + +[tool.isort] +profile = "black" + [build-system] requires = [ "setuptools>=42", diff --git a/setup.cfg b/setup.cfg index 0afa1eb5..2bcd70e3 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,47 +1,2 @@ -[metadata] -name = django-auth-ldap -description = Django LDAP authentication backend. -long_description = file: README.rst -long_description_content_type = text/x-rst -author = Peter Sagerson -author_email = psagers@ignorare.net -url = https://github.com/django-auth-ldap/django-auth-ldap -license = BSD -classifiers = - Development Status :: 5 - Production/Stable - Environment :: Web Environment - Framework :: Django - Framework :: Django :: 3.2 - Framework :: Django :: 4.1 - Framework :: Django :: 4.2 - Intended Audience :: Developers - Intended Audience :: System Administrators - License :: OSI Approved :: BSD License - Programming Language :: Python - Programming Language :: Python :: 3 - Programming Language :: Python :: 3 :: Only - 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 - Topic :: Internet :: WWW/HTTP - Topic :: Software Development :: Libraries :: Python Modules - Topic :: System :: Systems Administration :: Authentication/Directory :: LDAP -project_urls = - Documentation = https://django-auth-ldap.readthedocs.io/ - Source = https://github.com/django-auth-ldap/django-auth-ldap - Tracker = https://github.com/django-auth-ldap/django-auth-ldap/issues - Changelog = https://github.com/django-auth-ldap/django-auth-ldap/releases/ - -[options] -python_requires = >=3.7 -install_requires = - Django>=3.2 - python-ldap>=3.1 - [flake8] max-line-length = 88 - -[isort] -profile = black From 660ed3daf43c45b945815226ab89ccede40aca6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Wed, 7 Jun 2023 09:38:14 +0200 Subject: [PATCH 07/10] Test against Python 3.12-dev --- .github/workflows/test.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e2618178..6696bfe2 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -18,6 +18,7 @@ jobs: - 3.9 - '3.10' - '3.11' + - '3.12-dev' tox-environment: - django41 - django42 From b3b3dad0ee6d3ca2398a20ff2bedb8e6bd16c941 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Mon, 17 Jul 2023 09:23:47 +0200 Subject: [PATCH 08/10] Drop support for Python 3.7 --- .github/workflows/test.yml | 2 -- docs/index.rst | 2 +- pyproject.toml | 3 +-- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6696bfe2..9c9a8a98 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -24,8 +24,6 @@ jobs: - django42 include: # Django 3.2 - - python-version: 3.7 - tox-environment: django32 - python-version: 3.8 tox-environment: django32 - python-version: 3.9 diff --git a/docs/index.rst b/docs/index.rst index 44fc1587..4b09f170 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -12,7 +12,7 @@ groups, and permissions. * Repository: https://github.com/django-auth-ldap/django-auth-ldap * License: BSD 2-Clause -This version is supported on Python 3.7+; and Django 2.2+. It requires +This version is supported on Python 3.8+; and Django 2.2+. It requires `python-ldap`_ >= 3.1. .. toctree:: diff --git a/pyproject.toml b/pyproject.toml index 9db6fb26..4b8057d5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "django-auth-ldap" -requires-python = ">=3.7" +requires-python = ">=3.8" description = "Django LDAP authentication backend" readme = "README.rst" authors = [ @@ -23,7 +23,6 @@ classifiers = [ "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", From 46d96627daeebda2163cbcd8c3386d0eb6c87263 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Sat, 22 Jul 2023 17:46:30 +0200 Subject: [PATCH 09/10] Move building a release and uploading to PyPI to GitHub actions https://packaging.python.org/en/latest/guides/publishing-package-distribution-releases-using-github-actions-ci-cd-workflows/ --- .github/workflows/build.yml | 33 ++++++++++++++++++++++++++++++++ .github/workflows/packaging.yml | 34 --------------------------------- .github/workflows/release.yml | 26 +++++++++++++++++++++++++ tox.ini | 11 ----------- 4 files changed, 59 insertions(+), 45 deletions(-) create mode 100644 .github/workflows/build.yml delete mode 100644 .github/workflows/packaging.yml create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..359117c5 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,33 @@ +name: Build distribution files + +on: + release: + types: [published] + +jobs: + test: + name: Build distribution files + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: "3.x" + + - name: Install dependencies + run: pip install --user build setuptools twine wheel + + - name: Build package + run: python -m build + + - name: Verify package + run: twine check --strict dist/* + + - name: Upload package to GitHub + uses: actions/upload-artifact@v3 + with: + name: dist + path: dist/ + if-no-files-found: error diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml deleted file mode 100644 index 4e3d2e77..00000000 --- a/.github/workflows/packaging.yml +++ /dev/null @@ -1,34 +0,0 @@ -name: Packaging - -on: - - push - - pull_request - -jobs: - test: - name: Packaging - runs-on: ubuntu-latest - - env: - TOXENV: packaging - - steps: - - name: Install LDAP libs - run: | - sudo apt-get update - # https://www.python-ldap.org/en/latest/installing.html#debian - sudo apt-get install slapd ldap-utils libldap2-dev libsasl2-dev - # https://github.com/python-ldap/python-ldap/issues/370 - sudo apt-get install apparmor-utils - sudo aa-disable /usr/sbin/slapd - - - uses: actions/checkout@v3 - - - name: Set up Python - uses: actions/setup-python@v4 - - - name: Install dependencies - run: python -m pip install tox - - - name: Run tests - run: tox diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..53340ca7 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,26 @@ +name: Upload release to PyPI +on: + workflow_run: + workflows: [Build distribution files] + types: [completed] + +jobs: + on-success: + if: ${{ github.event.workflow_run.conclusion == 'success' }} + runs-on: ubuntu-latest + environment: + name: Publish to PyPI + url: https://pypi.org/p/django-auth-ldap + permissions: + id-token: write + steps: + - name: Retrieve artifacts + uses: actions/download-artifact@v3 + with: + name: dist + path: dist/ + + - name: Publish distribution to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + password: ${{ secrets.PYPI_API_TOKEN }} diff --git a/tox.ini b/tox.ini index b003b3a9..50406922 100644 --- a/tox.ini +++ b/tox.ini @@ -41,14 +41,3 @@ deps = commands = make -C docs html allowlist_externals = make - -[testenv:packaging] -deps = - build - setuptools - twine - wheel -skip_install = true -commands = - python -m build - twine check --strict dist/* From 342c1039a1932942b450a00bd27f97b1b50d2598 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Freitag?= Date: Sat, 22 Jul 2023 20:18:55 +0200 Subject: [PATCH 10/10] Unify release workflow Makes orchestration much easier. --- .github/workflows/build.yml | 33 ------------------------------ .github/workflows/release.yml | 38 ++++++++++++++++++++++++++++------- 2 files changed, 31 insertions(+), 40 deletions(-) delete mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml deleted file mode 100644 index 359117c5..00000000 --- a/.github/workflows/build.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: Build distribution files - -on: - release: - types: [published] - -jobs: - test: - name: Build distribution files - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: "3.x" - - - name: Install dependencies - run: pip install --user build setuptools twine wheel - - - name: Build package - run: python -m build - - - name: Verify package - run: twine check --strict dist/* - - - name: Upload package to GitHub - uses: actions/upload-artifact@v3 - with: - name: dist - path: dist/ - if-no-files-found: error diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 53340ca7..8ccfd813 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,12 +1,38 @@ name: Upload release to PyPI on: - workflow_run: - workflows: [Build distribution files] - types: [completed] + release: + types: [published] jobs: - on-success: - if: ${{ github.event.workflow_run.conclusion == 'success' }} + build: + name: Build distribution files + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: "3.x" + + - name: Install dependencies + run: pip install --user build setuptools twine wheel + + - name: Build package + run: python -m build + + - name: Verify package + run: twine check --strict dist/* + + - name: Upload package to GitHub + uses: actions/upload-artifact@v3 + with: + name: dist + path: dist/ + if-no-files-found: error + + release: + needs: build runs-on: ubuntu-latest environment: name: Publish to PyPI @@ -22,5 +48,3 @@ jobs: - name: Publish distribution to PyPI uses: pypa/gh-action-pypi-publish@release/v1 - with: - password: ${{ secrets.PYPI_API_TOKEN }} pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy