Remove unused internal code

This commit is contained in:
duriantaco 2026-03-11 13:48:20 +08:00
parent 4cae5d8e41
commit d62e0c81b8
2 changed files with 0 additions and 14 deletions

View file

@ -687,14 +687,6 @@ class FlaskGroup(AppGroup):
return super().parse_args(ctx, args)
def _path_is_ancestor(path: str, other: str) -> bool:
"""Take ``other`` and remove the length of ``path`` from it. Then join it
to ``path``. If it is the original value, ``path`` is an ancestor of
``other``."""
return os.path.join(path, other[len(path) :].lstrip(os.sep)) == other
def load_dotenv(
path: str | os.PathLike[str] | None = None, load_defaults: bool = True
) -> bool:

View file

@ -14,12 +14,6 @@ if t.TYPE_CHECKING:
from .wrappers import Request
class UnexpectedUnicodeError(AssertionError, UnicodeError):
"""Raised in places where we want some better error reporting for
unexpected unicode or binary data.
"""
class DebugFilesKeyError(KeyError, AssertionError):
"""Raised from request.files during debugging. The idea is that it can
provide a better error message than just a generic KeyError/BadRequest.