FileField doesn't clean up directory after deletion
|Reported by:||Michiel_1981||Owned by:||nobody|
|Cc:||Triage Stage:||Design decision needed|
|Has patch:||no||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
If a FileField file is being deleted it doesn't clean up a empty directory that might occur after deletion.
This is only a issue if you use a dynamic path based on date.
If this is the case then you could create a lot of empty directories and/or nested empty directories.
class MetaFile(models.Model): file = models.FileField(_("File"), max_length=255, upload_to='meta/%y/%m')
Change History (10)
comment:1 Changed 8 years ago by Gulopine
- Keywords fs-rf added
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset
comment:3 Changed 7 years ago by MichaelBishop
- Triage Stage changed from Unreviewed to Design decision needed