_prepare_send_file_kwargs() — flask Function Reference
Architecture documentation for the _prepare_send_file_kwargs() function in helpers.py from the flask codebase.
Entity Profile
Dependency Diagram
graph TD 04d28ef5_1747_490a_b80c_227d53a1ec17["_prepare_send_file_kwargs()"] 881f9803_28d6_7d77_c8d7_1098b41ccf84["helpers.py"] 04d28ef5_1747_490a_b80c_227d53a1ec17 -->|defined in| 881f9803_28d6_7d77_c8d7_1098b41ccf84 0aece18f_0f2e_c352_3956_f4c49e3d7d4f["send_file()"] 0aece18f_0f2e_c352_3956_f4c49e3d7d4f -->|calls| 04d28ef5_1747_490a_b80c_227d53a1ec17 cd968d21_9286_02d4_74b3_ae5e22f8a986["send_from_directory()"] cd968d21_9286_02d4_74b3_ae5e22f8a986 -->|calls| 04d28ef5_1747_490a_b80c_227d53a1ec17 b7db9b24_d5be_a8c2_55fe_26b8b73ffe93["_get_current_object()"] 04d28ef5_1747_490a_b80c_227d53a1ec17 -->|calls| b7db9b24_d5be_a8c2_55fe_26b8b73ffe93 style 04d28ef5_1747_490a_b80c_227d53a1ec17 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
src/flask/helpers.py lines 389–401
def _prepare_send_file_kwargs(**kwargs: t.Any) -> dict[str, t.Any]:
ctx = app_ctx._get_current_object()
if kwargs.get("max_age") is None:
kwargs["max_age"] = ctx.app.get_send_file_max_age
kwargs.update(
environ=ctx.request.environ,
use_x_sendfile=ctx.app.config["USE_X_SENDFILE"],
response_class=ctx.app.response_class,
_root_path=ctx.app.root_path,
)
return kwargs
Domain
Subdomains
Defined In
Calls
Called By
Source
Frequently Asked Questions
What does _prepare_send_file_kwargs() do?
_prepare_send_file_kwargs() is a function in the flask codebase, defined in src/flask/helpers.py.
Where is _prepare_send_file_kwargs() defined?
_prepare_send_file_kwargs() is defined in src/flask/helpers.py at line 389.
What does _prepare_send_file_kwargs() call?
_prepare_send_file_kwargs() calls 1 function(s): _get_current_object.
What calls _prepare_send_file_kwargs()?
_prepare_send_file_kwargs() is called by 2 function(s): send_file, send_from_directory.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free