-
-
Notifications
You must be signed in to change notification settings - Fork 955
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add max_part_size
parameter to MultiPartParser
#2815
Conversation
Addresses issue reported in encode#2785
starlette/formparsers.py
Outdated
max_file_size: int = 1024 * 1024, # 1MB | ||
max_part_size: int | float = 1024 * 1024, # 1MB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we remove defaults here and keep the default at top most function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is okay.
starlette/formparsers.py
Outdated
max_file_size: int = 1024 * 1024, # 1MB | ||
max_part_size: int | float = 1024 * 1024, # 1MB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is okay.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect! Thanks. :)
max_part_size
customizablemax_part_size
parameter to MultiPartParser
Fixes #2785
Also addresses issue discussed in FastAPI Repo.