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" diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 00d843e3..db760ebf 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -21,10 +21,10 @@ jobs: TOXENV: ${{ matrix.tox-environment }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - 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..9830a524 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -22,10 +22,10 @@ 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@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 deleted file mode 100644 index 8f808632..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@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - - - 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..8ccfd813 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,50 @@ +name: Upload release to PyPI +on: + release: + types: [published] + +jobs: + 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 + 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 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index df8e4143..9c9a8a98 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -18,13 +18,12 @@ jobs: - 3.9 - '3.10' - '3.11' + - '3.12-dev' tox-environment: - django41 - django42 include: # Django 3.2 - - python-version: 3.7 - tox-environment: django32 - python-version: 3.8 tox-environment: django32 - python-version: 3.9 @@ -50,10 +49,10 @@ 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@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} 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 b749ea1d..4b8057d5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,53 @@ +[project] +name = "django-auth-ldap" +requires-python = ">=3.8" +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.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 68aa559d..2bcd70e3 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,48 +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 -packages = django_auth_ldap -install_requires = - Django>=3.2 - python-ldap>=3.1 - [flake8] max-line-length = 88 - -[isort] -profile = black diff --git a/tox.ini b/tox.ini index d24e399a..50406922 100644 --- a/tox.ini +++ b/tox.ini @@ -5,8 +5,8 @@ envlist = isort docs django32 - django40 django41 + django42 djangomain isolated_build = true @@ -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/*
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: