jalmenarez / minify

Automatically exported from code.google.com/p/minify
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Stale cache files are being output #70

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Minify version: 2.1.1
PHP version: 5.2.5

What steps will reproduce the problem?
1. Just modify a file minified by Minify and refresh in the browser

Expected output:
Cache should have been rebuilt.
Actual output:
The output will be served from cache

Did you run the unit tests? Did any FAIL?
Not 2.1.1.
Please provide any additional information below.
I was looking for the code section which checks the last modified time of
the files against the cache and couldn't find it. The digest for the
sources doesn't include the last modify time, only name, minifiers and
options, so a newer file has the same digest as the older one in the cache.

Original issue reported on code.google.com by gye...@gmail.com on 22 Nov 2008 at 9:56

GoogleCodeExporter commented 9 years ago
Are you uploading from Windows? Check near the bottom of your config file for 
info 
and a possible workaround:
http://code.google.com/p/minify/source/browse/tags/release_2.1.1/min/config.php#
79
I changed my settings in WinSCP and it took care of this.

BTW, the lmtime check is done here:
http://code.google.com/p/minify/source/browse/tags/release_2.1.1/min/lib/Minify/
Cache/File.php#59

Original comment by mrclay....@gmail.com on 22 Nov 2008 at 10:19

GoogleCodeExporter commented 9 years ago
I'm sorry, but isn't this function used to check the cache file against the
if-changed-since header? I am interested in the source files' last modified 
time check.

Original comment by gye...@gmail.com on 22 Nov 2008 at 10:34

GoogleCodeExporter commented 9 years ago
But anyway, you were right. The issue was uploading from Windows.

Original comment by gye...@gmail.com on 22 Nov 2008 at 10:45

GoogleCodeExporter commented 9 years ago
Sorry, the source lmtimes are checked here:
http://code.google.com/p/minify/source/browse/tags/release_2.1.1/min/lib/Minify/
Source.php#59

Original comment by mrclay....@gmail.com on 22 Nov 2008 at 11:11