Chuma Umenze
3 years ago
13 changed files with 1542 additions and 232 deletions
-
2.github/workflows/publish.yaml
-
25CONTRIBUTING.md
-
15Pipfile
-
107Pipfile.lock
-
5dev-requirements.txt
-
9docs-requirements.txt
-
1433poetry.lock
-
71pyproject.toml
-
3requirements.txt
-
2setup.cfg
-
58setup.py
-
2src/keycloak/keycloak_admin.py
-
42tox.ini
@ -1,15 +0,0 @@ |
|||
[[source]] |
|||
url = "https://pypi.org/simple" |
|||
verify_ssl = true |
|||
name = "pypi" |
|||
|
|||
[packages] |
|||
requests = ">=2.20.0" |
|||
httmock = ">=1.2.5" |
|||
python-jose = ">=1.4.0" |
|||
urllib3 = ">=1.26.5" |
|||
|
|||
[dev-packages] |
|||
|
|||
[requires] |
|||
python_version = "3.7" |
@ -1,107 +0,0 @@ |
|||
{ |
|||
"_meta": { |
|||
"hash": { |
|||
"sha256": "8c12705e89c665da92fc69ef0d312a9ca313703c839c15d18fcc833dcb87d7f7" |
|||
}, |
|||
"pipfile-spec": 6, |
|||
"requires": { |
|||
"python_version": "3.7" |
|||
}, |
|||
"sources": [ |
|||
{ |
|||
"name": "pypi", |
|||
"url": "https://pypi.org/simple", |
|||
"verify_ssl": true |
|||
} |
|||
] |
|||
}, |
|||
"default": { |
|||
"certifi": { |
|||
"hashes": [ |
|||
"sha256:1a4995114262bffbc2413b159f2a1a480c969de6e6eb13ee966d470af86af59c", |
|||
"sha256:719a74fb9e33b9bd44cc7f3a8d94bc35e4049deebe19ba7d8e108280cfd59830" |
|||
], |
|||
"version": "==2020.12.5" |
|||
}, |
|||
"chardet": { |
|||
"hashes": [ |
|||
"sha256:84ab92ed1c4d4f16916e05906b6b75a6c0fb5db821cc65e70cbd64a3e2a5eaae", |
|||
"sha256:fc323ffcaeaed0e0a02bf4d117757b98aed530d9ed4531e3e15460124c106691" |
|||
], |
|||
"version": "==3.0.4" |
|||
}, |
|||
"ecdsa": { |
|||
"hashes": [ |
|||
"sha256:881fa5e12bb992972d3d1b3d4dfbe149ab76a89f13da02daa5ea1ec7dea6e747", |
|||
"sha256:cfc046a2ddd425adbd1a78b3c46f0d1325c657811c0f45ecc3a0a6236c1e50ff" |
|||
], |
|||
"version": "==0.16.1" |
|||
}, |
|||
"future": { |
|||
"hashes": [ |
|||
"sha256:b1bead90b70cf6ec3f0710ae53a525360fa360d306a86583adc6bf83a4db537d" |
|||
], |
|||
"version": "==0.18.2" |
|||
}, |
|||
"httmock": { |
|||
"hashes": [ |
|||
"sha256:4696306d1ff835c3ca865fdef2684d7e130b4120cc00126f862ba4797b1602ac" |
|||
], |
|||
"index": "pypi", |
|||
"version": "==1.2.6" |
|||
}, |
|||
"idna": { |
|||
"hashes": [ |
|||
"sha256:156a6814fb5ac1fc6850fb002e0852d56c0c8d2531923a51032d1b70760e186e", |
|||
"sha256:684a38a6f903c1d71d6d5fac066b58d7768af4de2b832e426ec79c30daa94a16" |
|||
], |
|||
"version": "==2.7" |
|||
}, |
|||
"pyasn1": { |
|||
"hashes": [ |
|||
"sha256:39c7e2ec30515947ff4e87fb6f456dfc6e84857d34be479c9d4a4ba4bf46aa5d", |
|||
"sha256:aef77c9fb94a3ac588e87841208bdec464471d9871bd5050a287cc9a475cd0ba" |
|||
], |
|||
"version": "==0.4.8" |
|||
}, |
|||
"python-jose": { |
|||
"hashes": [ |
|||
"sha256:29701d998fe560e52f17246c3213a882a4a39da7e42c7015bcc1f7823ceaff1c", |
|||
"sha256:ed7387f0f9af2ea0ddc441d83a6eb47a5909bd0c8a72ac3250e75afec2cc1371" |
|||
], |
|||
"index": "pypi", |
|||
"version": "==3.0.1" |
|||
}, |
|||
"requests": { |
|||
"hashes": [ |
|||
"sha256:63b52e3c866428a224f97cab011de738c36aec0185aa91cfacd418b5d58911d1", |
|||
"sha256:ec22d826a36ed72a7358ff3fe56cbd4ba69dd7a6718ffd450ff0e9df7a47ce6a" |
|||
], |
|||
"index": "pypi", |
|||
"version": "==2.19.1" |
|||
}, |
|||
"rsa": { |
|||
"hashes": [ |
|||
"sha256:69805d6b69f56eb05b62daea3a7dbd7aa44324ad1306445e05da8060232d00f4", |
|||
"sha256:a8774e55b59fd9fc893b0d05e9bfc6f47081f46ff5b46f39ccf24631b7be356b" |
|||
], |
|||
"index": "pypi", |
|||
"version": "==4.7" |
|||
}, |
|||
"six": { |
|||
"hashes": [ |
|||
"sha256:30639c035cdb23534cd4aa2dd52c3bf48f06e5f4a941509c8bafd8ce11080259", |
|||
"sha256:8b74bedcbbbaca38ff6d7491d76f2b06b3592611af620f8426e82dddb04a5ced" |
|||
], |
|||
"version": "==1.15.0" |
|||
}, |
|||
"urllib3": { |
|||
"hashes": [ |
|||
"sha256:a68ac5e15e76e7e5dd2b8f94007233e01effe3e50e8daddf69acfd81cb686baf", |
|||
"sha256:b5725a0bd4ba422ab0e66e89e030c806576753ea3ee08554382c14e685d117b5" |
|||
], |
|||
"version": "==1.23" |
|||
} |
|||
}, |
|||
"develop": {} |
|||
} |
@ -1,5 +0,0 @@ |
|||
tox |
|||
pytest |
|||
pytest-cov |
|||
wheel |
|||
pre-commit |
@ -1,9 +0,0 @@ |
|||
mock |
|||
alabaster |
|||
commonmark |
|||
recommonmark |
|||
sphinx |
|||
sphinx-rtd-theme |
|||
readthedocs-sphinx-ext |
|||
m2r2 |
|||
sphinx-autoapi |
1433
poetry.lock
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -1,3 +0,0 @@ |
|||
requests>=2.20.0 |
|||
python-jose>=1.4.0 |
|||
urllib3>=1.26.0 |
@ -1,2 +0,0 @@ |
|||
[metadata] |
|||
description-file = README.md |
@ -1,58 +0,0 @@ |
|||
# -*- coding: utf-8 -*- |
|||
import re |
|||
|
|||
from setuptools import find_packages, setup |
|||
|
|||
with open("README.md", "r") as fh: |
|||
long_description = fh.read() |
|||
|
|||
with open("requirements.txt", "r") as fh: |
|||
reqs = fh.read().split("\n") |
|||
|
|||
with open("dev-requirements.txt", "r") as fh: |
|||
dev_reqs = fh.read().split("\n") |
|||
|
|||
with open("docs-requirements.txt", "r") as fh: |
|||
docs_reqs = fh.read().split("\n") |
|||
|
|||
|
|||
VERSIONFILE = "src/keycloak/_version.py" |
|||
verstrline = open(VERSIONFILE, "rt").read() |
|||
VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" |
|||
mo = re.search(VSRE, verstrline, re.M) |
|||
if mo: |
|||
verstr = mo.group(1) |
|||
else: |
|||
raise RuntimeError("Unable to find version string in %s." % (VERSIONFILE,)) |
|||
|
|||
setup( |
|||
name="python-keycloak", |
|||
version=verstr, |
|||
url="https://github.com/marcospereirampj/python-keycloak", |
|||
license="The MIT License", |
|||
author="Marcos Pereira, Richard Nemeth", |
|||
author_email="marcospereira.mpj@gmail.com, ryshoooo@gmail.com", |
|||
keywords="keycloak openid oidc", |
|||
description="python-keycloak is a Python package providing access to the Keycloak API.", |
|||
long_description=long_description, |
|||
long_description_content_type="text/markdown", |
|||
packages=find_packages("src"), |
|||
package_dir={"": "src"}, |
|||
install_requires=reqs, |
|||
tests_require=dev_reqs, |
|||
extras_require={"docs": docs_reqs}, |
|||
python_requires=">=3.7", |
|||
project_urls={ |
|||
"Documentation": "https://python-keycloak.readthedocs.io/en/latest/", |
|||
"Issue tracker": "https://github.com/marcospereirampj/python-keycloak/issues", |
|||
}, |
|||
classifiers=[ |
|||
"Programming Language :: Python :: 3", |
|||
"License :: OSI Approved :: MIT License", |
|||
"Development Status :: 3 - Alpha", |
|||
"Operating System :: MacOS", |
|||
"Operating System :: Unix", |
|||
"Operating System :: Microsoft :: Windows", |
|||
"Topic :: Utilities", |
|||
], |
|||
) |
@ -1,48 +1,44 @@ |
|||
[tox] |
|||
isolated_build = true |
|||
envlist = check, apply-check, docs, tests, build |
|||
|
|||
[testenv] |
|||
install_command = pip install {opts} {packages} |
|||
deps = |
|||
poetry>=1.1.13 |
|||
commands_pre = |
|||
bash -c "python -m pip install -r <(poetry export --dev --extras=docs --no-interaction)" |
|||
whitelist_externals = |
|||
bash |
|||
|
|||
[testenv:check] |
|||
deps = |
|||
black |
|||
isort |
|||
flake8 |
|||
commands = |
|||
black --check --diff src/keycloak tests docs setup.py |
|||
isort -c --df src/keycloak tests docs setup.py |
|||
flake8 src/keycloak tests docs setup.py |
|||
black --check --diff src/keycloak tests docs |
|||
isort -c --df src/keycloak tests docs |
|||
flake8 src/keycloak tests docs |
|||
|
|||
[testenv:apply-check] |
|||
deps = |
|||
black |
|||
isort |
|||
flake8 |
|||
commands = |
|||
black -C src/keycloak tests docs setup.py |
|||
black src/keycloak tests docs setup.py |
|||
isort src/keycloak tests docs setup.py |
|||
black -C src/keycloak tests docs |
|||
black src/keycloak tests docs |
|||
isort src/keycloak tests docs |
|||
|
|||
[testenv:docs] |
|||
deps = |
|||
.[docs] |
|||
commands = |
|||
python -m sphinx -T -E -W -b html -d _build/doctrees -D language=en ./docs/source _build/html |
|||
sphinx-build -T -E -W -b html -d _build/doctrees -D language=en ./docs/source _build/html |
|||
|
|||
[testenv:tests] |
|||
setenv = file|tox.env |
|||
deps = |
|||
-rrequirements.txt |
|||
-rdev-requirements.txt |
|||
commands = |
|||
./test_keycloak_init.sh "pytest -vv --cov=keycloak --cov-report term-missing {posargs}" |
|||
|
|||
[testenv:build] |
|||
deps = |
|||
-rdev-requirements.txt |
|||
commands_pre = |
|||
setenv = |
|||
POETRY_VIRTUALENVS_CREATE = false |
|||
commands = |
|||
python setup.py sdist bdist_wheel |
|||
poetry build --format sdist |
|||
poetry build --format wheel |
|||
|
|||
[flake8] |
|||
max-line-length = 99 |
Write
Preview
Loading…
Cancel
Save
Reference in new issue