-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
Code of Conduct
- I agree to follow Django's Code of Conduct
Feature Description
hi
adding validation for max size and min size of files
Problem
since files can be uploaded by users, having some validation on them could become necessary for developers
Request or proposal
proposal
Additional Details
this was discussed in https://forum.djangoproject.com/t/proposal-max-and-min-size-validation-for-filefield/43232 and https://code.djangoproject.com/ticket/36685
we already get size of the file in the to_python method in form field and check for empty files
might just turn it into checking both side of size
Implementation Suggestions
this could be either a validator function that will be added to list of validators
or a parameter to FileField itself, which could be validated in the validate method
LilyFirefly, UnknownPlatypus, ericpalakovichcarr, adamchainz, knyghty and 2 more
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Idea