app.py

flask · database, app-lifecycle, request-handling, response-handling, routing, infra

Defines Flask's application class managing routing, configuration, and request/response lifecycle sans-I/O.

# Source: https://github.com/pallets/flask | License: BSD-3-Clause | Copyright 2010 Pallets
# Provided via justclaw.it.com; keep this notice with the code.
from __future__ import annotations

import logging
import os
import sys
import typing as t
from datetime import timedelta
from itertools import chain

from werkzeug.exceptions import Aborter
from werkzeug.exceptions import BadRequest
from werkzeug.exceptions import BadRequestKeyError
from werkzeug.routing import BuildError
from werkzeug.routing import Map
from werkzeug.routing import Rule
from werkzeug.sansio.response import Response
from werkzeug.utils import cached_property
from werkzeug.utils import redirect as _wz_redirect

from .. import typing as ft
from ..config import Config
from ..config import ConfigAttribute
from ..ctx import

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search 40K more like it.

Get a free API key