You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In light of the issues and PRs relating to BaseHTTPMiddleware we need to improve the documentation on this middleware class and give some good guidance on how to write custom middleware. Documentation on this should include the following:
A warning not to use BaseHTTPMiddleware with StreamingResponse or FileResponse endpoints.
A note on how background will be evaluated with respect to BaseHTTPMiddleware.
Instructions on how to write custom ASGI Middleware with example code (can be based on an example from the codebase).
A gentle suggestion to favor custom ASGI Middleware over subclassing BaseHTTPMiddleware.
In light of the issues and PRs relating to
BaseHTTPMiddleware
we need to improve the documentation on this middleware class and give some good guidance on how to write custom middleware. Documentation on this should include the following:BaseHTTPMiddleware
withStreamingResponse
orFileResponse
endpoints.BaseHTTPMiddleware
.BaseHTTPMiddleware
.See related issues and PRs:
BaseHTTPMiddleware
#919The text was updated successfully, but these errors were encountered: