﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
28603	collectstatic passes all files to post_process(), contrary to code comment	Ed Morley	Ed Morley	"In the collectstatic's `collect()` function ([https://github.com/django/django/blob/8f947730ca6a9e3e538a377e7993e17ce3663ee6/django/contrib/staticfiles/management/commands/collectstatic.py#L124-L125 source]), there is this comment:

{{{#!python
        # Here we check if the storage backend has a post_process
        # method and pass it the list of modified files.
}}}

However contrary to that comment,`post_process()` is actually passed the list of all found files, not just the modified files:
https://github.com/django/django/blob/8f947730ca6a9e3e538a377e7993e17ce3663ee6/django/contrib/staticfiles/management/commands/collectstatic.py#L127

I'm pretty passing all files is necessary, since if only the modified files were passed and someone had changed the storage backend since the last collectstatic run, then the existing files wouldn't have the necessary post processing applied.

As such, I believe it's the comment that's wrong rather than the implementation, but it would be good to have confirmation :-)"	Cleanup/optimization	closed	contrib.staticfiles	dev	Normal	fixed	collectstatic		Ready for checkin	1	0	0	0	0	0
