Skip to content

Commit

Permalink
make packages private
Browse files Browse the repository at this point in the history
  • Loading branch information
CheeseCake87 committed Sep 19, 2024
1 parent 2ebd10e commit 87a5b82
Show file tree
Hide file tree
Showing 36 changed files with 52 additions and 52 deletions.
4 changes: 2 additions & 2 deletions src/flask_imp/__init__.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from .__version__ import __version__
from .auth import Auth as Auth
from .auth import PasswordGeneration as PasswordGeneration
from .imp import Imp as Imp
from .imp_blueprint import ImpBlueprint
from ._imp import Imp as Imp
from ._imp_blueprint import ImpBlueprint

__all__ = [
"__version__",
Expand Down
File renamed without changes.
6 changes: 3 additions & 3 deletions src/flask_imp/imp.py → src/flask_imp/_imp.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
from flask_sqlalchemy.model import DefaultMeta

from .config import ImpConfig
from .imp_blueprint import ImpBlueprint
from .registeries import ModelRegistry
from .utilities import cast_to_import_str, build_database_main, build_database_binds
from ._imp_blueprint import ImpBlueprint
from ._registries import ModelRegistry
from ._utilities import cast_to_import_str, build_database_main, build_database_binds


class Imp:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@

from .config import DatabaseConfig
from .config import ImpBlueprintConfig
from .exceptions import NoConfigProvided
from .utilities import (
from ._exceptions import NoConfigProvided
from ._utilities import (
cast_to_import_str,
slug,
_partial_models_import,
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/flask_imp/utilities.py → src/flask_imp/_utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from flask import Flask
from flask_imp.config import DatabaseConfig, SQLDatabaseConfig, SQLiteDatabaseConfig

from .protocols import Imp
from ._protocols import Imp


class Sprinkles:
Expand Down
26 changes: 13 additions & 13 deletions src/flask_imp/auth/__init__.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
from .__legacy__ import Auth
from .authenticate_password import authenticate_password
from .dataclasses import PasswordGeneration
from .encrypt_password import encrypt_password
from .generate_alphanumeric_validator import generate_alphanumeric_validator
from .generate_csrf_token import generate_csrf_token
from .generate_email_validator import generate_email_validator
from .generate_numeric_validator import generate_numeric_validator
from .generate_password import generate_password
from .generate_private_key import generate_private_key
from .generate_salt import generate_salt
from .is_email_address_valid import is_email_address_valid
from .is_username_valid import is_username_valid
from ._legacy import Auth
from ._authenticate_password import authenticate_password
from ._dataclasses import PasswordGeneration
from ._encrypt_password import encrypt_password
from ._generate_alphanumeric_validator import generate_alphanumeric_validator
from ._generate_csrf_token import generate_csrf_token
from ._generate_email_validator import generate_email_validator
from ._generate_numeric_validator import generate_numeric_validator
from ._generate_password import generate_password
from ._generate_private_key import generate_private_key
from ._generate_salt import generate_salt
from ._is_email_address_valid import is_email_address_valid
from ._is_username_valid import is_username_valid

__all__ = [
"PasswordGeneration",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

from more_itertools import batched

from .__private_funcs__ import _guess_block
from ._private_funcs import _guess_block


def authenticate_password(
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from random import choice
from string import ascii_letters

from .__private_funcs__ import _pps, _ppe
from ._private_funcs import _pps, _ppe


def encrypt_password(
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from .generate_alphanumeric_validator import generate_alphanumeric_validator
from ._generate_alphanumeric_validator import generate_alphanumeric_validator


def generate_email_validator() -> str:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from random import choice

from .dataclasses import PasswordGeneration
from .generate_numeric_validator import generate_numeric_validator
from ._dataclasses import PasswordGeneration
from ._generate_numeric_validator import generate_numeric_validator


def generate_password(style: str = "mixed", length: int = 3) -> str:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
22 changes: 11 additions & 11 deletions src/flask_imp/auth/__legacy__.py → src/flask_imp/auth/_legacy.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
from random import choice
from string import ascii_letters

from .authenticate_password import authenticate_password
from .encrypt_password import encrypt_password
from .generate_alphanumeric_validator import generate_alphanumeric_validator
from .generate_csrf_token import generate_csrf_token
from .generate_email_validator import generate_email_validator
from .generate_numeric_validator import generate_numeric_validator
from .generate_password import generate_password
from .generate_private_key import generate_private_key
from .generate_salt import generate_salt
from .is_email_address_valid import is_email_address_valid
from .is_username_valid import is_username_valid
from ._authenticate_password import authenticate_password
from ._encrypt_password import encrypt_password
from ._generate_alphanumeric_validator import generate_alphanumeric_validator
from ._generate_csrf_token import generate_csrf_token
from ._generate_email_validator import generate_email_validator
from ._generate_numeric_validator import generate_numeric_validator
from ._generate_password import generate_password
from ._generate_private_key import generate_private_key
from ._generate_salt import generate_salt
from ._is_email_address_valid import is_email_address_valid
from ._is_username_valid import is_username_valid


def auth_password(
Expand Down
File renamed without changes.
12 changes: 6 additions & 6 deletions src/flask_imp/config/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from .database_config import DatabaseConfig
from .sql_database_config import SQLDatabaseConfig
from .sqlite_database_config import SQLiteDatabaseConfig
from .flask_config import FlaskConfig
from .imp_blueprint_config import ImpBlueprintConfig
from .imp_config import ImpConfig
from ._database_config import DatabaseConfig
from ._sql_database_config import SQLDatabaseConfig
from ._sqlite_database_config import SQLiteDatabaseConfig
from ._flask_config import FlaskConfig
from ._imp_blueprint_config import ImpBlueprintConfig
from ._imp_config import ImpConfig

__all__ = [
"FlaskConfig",
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

@dataclass
class ImpBlueprintConfig:
from .database_config import DatabaseConfig
from ._database_config import DatabaseConfig

enabled: t.Optional[bool] = None
url_prefix: t.Optional[str] = None
Expand Down
File renamed without changes.
File renamed without changes.
10 changes: 5 additions & 5 deletions src/flask_imp/security/__init__.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from .api_login_check import api_login_check
from .include_csrf import include_csrf
from .login_check import login_check
from .pass_function_check import pass_function_check
from .permission_check import permission_check
from ._api_login_check import api_login_check
from ._include_csrf import include_csrf
from ._login_check import login_check
from ._pass_function_check import pass_function_check
from ._permission_check import permission_check

__all__ = [
"api_login_check",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

from flask import session

from .__private_funcs__ import _check_against_values_allowed
from ._private_funcs import _check_against_values_allowed


def api_login_check(
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from flask import session
from flask import url_for

from .__private_funcs__ import _check_against_values_allowed
from ._private_funcs import _check_against_values_allowed


def login_check(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from flask import session
from flask import url_for

from .__private_funcs__ import _check_against_values_allowed
from ._private_funcs import _check_against_values_allowed


def permission_check(
Expand Down
File renamed without changes.

0 comments on commit 87a5b82

Please sign in to comment.