Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -68,16 +68,16 @@ run-check-prettify: | deprecation-warning run-pre-test
$(TEST_DC) exec -T auth npm run prettify-check

run-check-black: | deprecation-warning run-pre-test
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth black --check --diff authlib/ tests/
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth black --check --diff osauthlib/ tests/

run-check-isort: | deprecation-warning run-pre-test
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth isort --check-only --diff authlib/ tests/
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth isort --check-only --diff osauthlib/ tests/

run-check-flake8: | deprecation-warning run-pre-test
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth flake8 authlib/ tests/
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth flake8 osauthlib/ tests/

run-check-mypy: | deprecation-warning run-pre-test
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth mypy authlib/ tests/
$(TEST_DC) exec -w /app/libraries/pip-auth/ -T auth mypy osauthlib/ tests/

run-cleanup-ci: | deprecation-warning build-dev
$(TEST_DC) up -d
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ The pip-library has the following API:

````python
# The class `AuthHandler` and the constants `AUTHENTICATION_HEADER`, `AUTHORIZATION_HEADER`, `COOKIE_NAME` are exported
from authlib import AuthHandler, AUTHENTICATION_HEADER, AUTHORIZATION_HEADER, COOKIE_NAME
from osauthlib import AuthHandler, AUTHENTICATION_HEADER, AUTHORIZATION_HEADER, COOKIE_NAME

authhandler = AuthHandler(debug_fn?) # Optional: a function to print debug information can be passed.
access_token = requests.headers.get(HEADER_NAME, NONE)
Expand Down
10 changes: 5 additions & 5 deletions auth/libraries/pip-auth/cleanup.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#/bin/bash

printf "Autoflake:\n"
autoflake authlib/ tests/
autoflake osauthlib/ tests/
printf "Black:\n"
black authlib/ tests/
black osauthlib/ tests/
printf "Isort:\n"
isort authlib/ tests/
isort osauthlib/ tests/
printf "Flake8:\n"
flake8 authlib/ tests/
flake8 osauthlib/ tests/
printf "Mypy:\n"
mypy authlib/ tests/
mypy osauthlib/ tests/
4 changes: 2 additions & 2 deletions auth/libraries/pip-auth/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
install_requires = [x.strip() for x in requirements.readlines()]

setuptools.setup(
name="authlib",
name="osauthlib",
version="1.0.0",
author="GabrielInTheWorld",
author_email="[email protected]",
Expand All @@ -20,7 +20,7 @@
url="https://github.com/OpenSlides/openslides-auth-service/auth/libraries/pip-auth",
packages=setuptools.find_packages(),
install_requires=install_requires,
package_data={"authlib": ["py.typed"]},
package_data={"osauthlib": ["py.typed"]},
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
Expand Down
4 changes: 2 additions & 2 deletions auth/libraries/pip-auth/tests/base.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import unittest

from authlib.auth_handler import AuthHandler
from authlib.message_bus import MessageBus
from osauthlib.auth_handler import AuthHandler
from osauthlib.message_bus import MessageBus

from .fake_request import FakeRequest

Expand Down
4 changes: 2 additions & 2 deletions auth/libraries/pip-auth/tests/fake_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

import requests

from authlib.constants import AUTHENTICATION_HEADER, COOKIE_NAME
from authlib.http_handler import HttpHandler
from osauthlib.constants import AUTHENTICATION_HEADER, COOKIE_NAME
from osauthlib.http_handler import HttpHandler


class FakeRequest:
Expand Down
6 changes: 3 additions & 3 deletions auth/libraries/pip-auth/tests/test_authenticate.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
import jwt
import pytest

from authlib.config import Environment
from authlib.constants import USER_ID_PROPERTY
from authlib.exceptions import AuthenticateException, InvalidCredentialsException
from osauthlib.config import Environment
from osauthlib.constants import USER_ID_PROPERTY
from osauthlib.exceptions import AuthenticateException, InvalidCredentialsException

from .base import BaseTestEnvironment

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

import jwt

from authlib.config import Environment
from authlib.constants import USER_ID_PROPERTY
from authlib.exceptions import InvalidCredentialsException
from osauthlib.config import Environment
from osauthlib.constants import USER_ID_PROPERTY
from osauthlib.exceptions import InvalidCredentialsException

from .base import BaseTestEnvironment

Expand Down
6 changes: 3 additions & 3 deletions auth/libraries/pip-auth/tests/test_authorize.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import pytest

from authlib.config import Environment
from authlib.constants import AUTHORIZATION_HEADER
from authlib.exceptions import AuthorizationException
from osauthlib.config import Environment
from osauthlib.constants import AUTHORIZATION_HEADER
from osauthlib.exceptions import AuthorizationException

from .base import BaseTestEnvironment

Expand Down
2 changes: 1 addition & 1 deletion auth/libraries/pip-auth/tests/test_hashing.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from authlib.hashing_handler import ARGON2_HASH_START
from osauthlib.hashing_handler import ARGON2_HASH_START

from .base import BaseTestEnvironment

Expand Down
2 changes: 1 addition & 1 deletion auth/libraries/pip-auth/tests/test_session_handler.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from time import time

from authlib.session_handler import Session, SessionHandler
from osauthlib.session_handler import Session, SessionHandler

from .base import BaseTestEnvironment

Expand Down