2024-01-03 10:09:31 +01:00
|
|
|
#
|
|
|
|
|
# People package
|
|
|
|
|
#
|
|
|
|
|
[build-system]
|
|
|
|
|
requires = ["setuptools"]
|
|
|
|
|
build-backend = "setuptools.build_meta"
|
|
|
|
|
|
|
|
|
|
[project]
|
|
|
|
|
name = "people"
|
2024-11-28 18:17:50 +01:00
|
|
|
version = "1.7.1"
|
2024-01-03 10:09:31 +01:00
|
|
|
authors = [{ "name" = "DINUM", "email" = "dev@mail.numerique.gouv.fr" }]
|
|
|
|
|
classifiers = [
|
|
|
|
|
"Development Status :: 5 - Production/Stable",
|
|
|
|
|
"Framework :: Django",
|
|
|
|
|
"Framework :: Django :: 5",
|
|
|
|
|
"Intended Audience :: Developers",
|
|
|
|
|
"License :: OSI Approved :: MIT License",
|
|
|
|
|
"Natural Language :: English",
|
|
|
|
|
"Programming Language :: Python :: 3",
|
|
|
|
|
"Programming Language :: Python :: 3.10",
|
|
|
|
|
]
|
|
|
|
|
description = "An application to handle contacts and teams."
|
|
|
|
|
keywords = ["Django", "Contacts", "Teams", "RBAC"]
|
|
|
|
|
license = { file = "LICENSE" }
|
|
|
|
|
readme = "README.md"
|
|
|
|
|
requires-python = ">=3.10"
|
|
|
|
|
dependencies = [
|
2024-12-02 12:59:08 +00:00
|
|
|
"boto3==1.35.72",
|
2024-01-03 10:09:31 +01:00
|
|
|
"Brotli==1.1.0",
|
2024-04-22 01:53:12 +00:00
|
|
|
"celery[redis]==5.4.0",
|
2024-04-02 08:54:36 +00:00
|
|
|
"django-configurations==2.5.1",
|
2024-10-30 09:37:00 +00:00
|
|
|
"django-cors-headers==4.6.0",
|
2024-04-02 08:54:36 +00:00
|
|
|
"django-countries==7.6.1",
|
2024-01-03 10:09:31 +01:00
|
|
|
"django-parler==2.3",
|
2024-10-30 09:37:00 +00:00
|
|
|
"redis==5.2.0",
|
2024-03-21 11:14:44 +00:00
|
|
|
"django-redis==5.4.0",
|
2024-07-21 22:14:39 +00:00
|
|
|
"django-storages==1.14.4",
|
2024-01-03 10:09:31 +01:00
|
|
|
"django-timezone-field>=5.1",
|
2024-12-06 19:40:05 +00:00
|
|
|
"django==5.1.4",
|
2024-06-27 16:09:02 +00:00
|
|
|
"djangorestframework==3.15.2",
|
2024-12-02 12:59:08 +00:00
|
|
|
"drf_spectacular==0.28.0",
|
2024-05-09 18:11:51 +00:00
|
|
|
"dockerflow==2024.4.2",
|
2024-09-17 16:36:13 +00:00
|
|
|
"easy_thumbnails==2.10",
|
2024-08-28 09:18:01 +00:00
|
|
|
"factory_boy==3.3.1",
|
|
|
|
|
"gunicorn==23.0.0",
|
2024-07-21 22:14:39 +00:00
|
|
|
"jsonschema==4.23.0",
|
2024-01-03 10:09:31 +01:00
|
|
|
"nested-multipart-parser==1.5.0",
|
2024-09-30 09:27:55 +00:00
|
|
|
"psycopg[binary]==3.2.3",
|
2024-12-02 12:59:08 +00:00
|
|
|
"PyJWT==2.10.1",
|
➕(backend) add a JOSE dependency
We will add a JWKs endpoint to the application
and manipulate signed/encrypted Json Web Token (JWT).
Project lacks tooling for JSON Object Signing and Encryption (JOSE)
manipulations. After a quick benchmark, 'joserfc' has been chosen
as the dependency to add.
joserfc is a Python library that provides a comprehensive
implementation of several essential JOSE standards.
Please find the benchmark:
- Cryptography: Although using only cryptography is feasible, its
interface/API is not as user-friendly.
- pyjwt: While pyjwt is popular, it lacks support for JWK and JWE objects,
which are essential for the requirements.
- python-jose: The latest release of python-jose was in 2021, and the
project seems less active compared to other alternatives.
- Authlib: Authlib is the second most popular library after pyjwt and seems
modern with an active community. However, the parts relevant to the use case
were extracted into a relatively new package named joserfc.
- joserfc: Although joserfc has fewer stars compared to Authlib, it was
extracted from Authlib, which has more than 4k stars, indicating a solid
foundation.
While the low star count of joserfc might raise concerns about its stability, it
is believed to be worth considering its addition. Adding Authlib and refactoring
later, once they finish migrating to joserfc, is also a possibility
2024-07-27 22:48:35 +02:00
|
|
|
"joserfc==1.0.0",
|
2024-07-21 22:14:39 +00:00
|
|
|
"requests==2.32.3",
|
2024-11-26 09:11:31 +00:00
|
|
|
"sentry-sdk[django]==2.19.0",
|
2024-10-30 09:37:00 +00:00
|
|
|
"whitenoise==6.8.2",
|
2024-03-21 11:14:44 +00:00
|
|
|
"mozilla-django-oidc==4.0.1",
|
2024-01-03 10:09:31 +01:00
|
|
|
]
|
|
|
|
|
|
|
|
|
|
[project.urls]
|
|
|
|
|
"Bug Tracker" = "https://github.com/numerique-gouv/people/issues/new"
|
|
|
|
|
"Changelog" = "https://github.com/numerique-gouv/people/blob/main/CHANGELOG.md"
|
|
|
|
|
"Homepage" = "https://github.com/numerique-gouv/people"
|
|
|
|
|
"Repository" = "https://github.com/numerique-gouv/people"
|
|
|
|
|
|
|
|
|
|
[project.optional-dependencies]
|
|
|
|
|
dev = [
|
|
|
|
|
"django-extensions==3.2.3",
|
2024-12-02 12:59:08 +00:00
|
|
|
"drf-spectacular-sidecar==2024.12.1",
|
2024-01-03 10:09:31 +01:00
|
|
|
"ipdb==0.13.13",
|
2024-12-02 12:59:08 +00:00
|
|
|
"ipython==8.30.0",
|
|
|
|
|
"pyfakefs==5.7.2",
|
2024-10-18 22:17:35 +00:00
|
|
|
"pylint-django==2.6.1",
|
2024-12-02 12:59:08 +00:00
|
|
|
"pylint==3.3.2",
|
2024-10-30 09:37:00 +00:00
|
|
|
"pytest-cov==6.0.0",
|
2024-09-05 04:56:10 +00:00
|
|
|
"pytest-django==4.9.0",
|
2024-12-02 12:59:08 +00:00
|
|
|
"pytest==8.3.4",
|
2024-01-29 13:43:32 +00:00
|
|
|
"pytest-icdiff==0.9",
|
2024-05-09 18:11:51 +00:00
|
|
|
"pytest-xdist==3.6.1",
|
2024-06-14 20:13:04 +00:00
|
|
|
"responses==0.25.3",
|
2024-12-02 12:59:08 +00:00
|
|
|
"ruff==0.8.1",
|
2024-10-18 22:17:35 +00:00
|
|
|
"types-requests==2.32.0.20241016",
|
2024-05-31 10:15:57 +00:00
|
|
|
"freezegun==1.5.1",
|
2024-01-03 10:09:31 +01:00
|
|
|
]
|
|
|
|
|
|
|
|
|
|
[tool.setuptools]
|
|
|
|
|
packages = { find = { where = ["."], exclude = ["tests"] } }
|
|
|
|
|
zip-safe = true
|
|
|
|
|
|
|
|
|
|
[tool.distutils.bdist_wheel]
|
|
|
|
|
universal = true
|
|
|
|
|
|
|
|
|
|
[tool.ruff]
|
|
|
|
|
exclude = [
|
|
|
|
|
".git",
|
|
|
|
|
".venv",
|
|
|
|
|
"build",
|
|
|
|
|
"venv",
|
|
|
|
|
"__pycache__",
|
|
|
|
|
"*/migrations/*",
|
|
|
|
|
]
|
|
|
|
|
line-length = 88
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[tool.ruff.lint]
|
|
|
|
|
select = [
|
|
|
|
|
"B", # flake8-bugbear
|
|
|
|
|
"BLE", # flake8-blind-except
|
|
|
|
|
"C4", # flake8-comprehensions
|
|
|
|
|
"DJ", # flake8-django
|
|
|
|
|
"I", # isort
|
|
|
|
|
"PLC", # pylint-convention
|
|
|
|
|
"PLE", # pylint-error
|
|
|
|
|
"PLR", # pylint-refactoring
|
|
|
|
|
"PLW", # pylint-warning
|
|
|
|
|
"RUF100", # Ruff unused-noqa
|
|
|
|
|
"RUF200", # Ruff check pyproject.toml
|
|
|
|
|
"S", # flake8-bandit
|
|
|
|
|
"SLF", # flake8-self
|
|
|
|
|
"T20", # flake8-print
|
2024-10-25 13:21:16 +02:00
|
|
|
"D1", # pydocstyle
|
2024-01-03 10:09:31 +01:00
|
|
|
]
|
2024-10-25 14:58:20 +02:00
|
|
|
ignore= ["DJ001", "PLR2004", "D105", "D106"]
|
2024-10-25 13:21:16 +02:00
|
|
|
|
2024-01-03 10:09:31 +01:00
|
|
|
[tool.ruff.lint.isort]
|
|
|
|
|
section-order = ["future","standard-library","django","third-party","people","first-party","local-folder"]
|
|
|
|
|
sections = { people=["core"], django=["django"] }
|
|
|
|
|
|
2024-03-07 11:01:16 +01:00
|
|
|
[tool.ruff.lint.per-file-ignores]
|
2024-01-03 10:09:31 +01:00
|
|
|
"**/tests/*" = ["S", "SLF"]
|
|
|
|
|
|
|
|
|
|
[tool.pytest.ini_options]
|
|
|
|
|
addopts = [
|
|
|
|
|
"-v",
|
|
|
|
|
"--cov-report",
|
|
|
|
|
"term-missing",
|
|
|
|
|
# Allow test files to have the same name in different directories.
|
|
|
|
|
"--import-mode=importlib",
|
|
|
|
|
]
|
|
|
|
|
python_files = [
|
|
|
|
|
"test_*.py",
|
|
|
|
|
"tests.py",
|
|
|
|
|
]
|
2024-08-01 12:27:04 +02:00
|
|
|
|
|
|
|
|
[tool.coverage.run]
|
|
|
|
|
branch = true
|
|
|
|
|
omit = [
|
|
|
|
|
"*/admin.py",
|
|
|
|
|
"*/migrations/*",
|
|
|
|
|
"*/tests/*",
|
|
|
|
|
"*/urls.py",
|
|
|
|
|
"manage.py",
|
|
|
|
|
"celery_app.py",
|
|
|
|
|
"wsgi.py",
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
[tool.coverage.report]
|
|
|
|
|
show_missing = true
|
|
|
|
|
skip_empty = true
|
|
|
|
|
|
|
|
|
|
[tool.coverage.json]
|
|
|
|
|
pretty_print = true
|