This project is archived and is in readonly mode.
expires_now broken
Reported by Mike Boone | March 11th, 2010 @ 08:42 PM | in 2.3.9
For Rails 2.3.x:
expires_now is supposed to set the Cache-Control header to "no-cache", but the header is overwritten to "private, max-age=0, must-revalidate". I suspect this is happening in actionpack/lib/action_controller/response.rb#set_conditional_cache_control! However, I don't understand the etag stuff well enough to mess with the code in handle_conditional_get! which is calling set_conditional_cache_control!.
Attached is a patch to the tests for expires_now, which fails.
Comments and changes to this ticket
-
Mike Boone March 11th, 2010 @ 08:43 PM
- Tag set to 2.3.x, cache-control
-
Mike Boone March 11th, 2010 @ 08:44 PM
- Tag changed from 2.3.x, cache-control to 2.3.x, actioncontroller, cache-control
-
Jeremy Kemper March 12th, 2010 @ 06:05 AM
- Milestone set to 2.3.6
- State changed from new to open
Thanks for the failing test, Mike!
-
Denis Odorcic March 14th, 2010 @ 10:34 AM
- Tag changed from 2.3.x, actioncontroller, cache-control to 2.3.x, actioncontroller, cache-control, patch
I've attached a patch for this and the failing test again because the original test had a name conflict.
-
Rizwan Reza May 16th, 2010 @ 02:41 AM
- Tag changed from 2.3.x, actioncontroller, cache-control, patch to 2.3.x, actioncontroller, bugmash, cache-control, patch
-
Rizwan Reza May 16th, 2010 @ 03:51 PM
- Tag changed from 2.3.x, actioncontroller, bugmash, cache-control, patch to 2.3.x, actioncontroller, bugmash-review, cache-control, patch
- State changed from open to verified
-
José Valim May 16th, 2010 @ 03:56 PM
Can someone check if this is an issue in Rails 3 (master) as well?
-
Rizwan Reza May 16th, 2010 @ 04:41 PM
- Tag changed from 2.3.x, actioncontroller, bugmash-review, cache-control, patch to 2.3.x, actioncontroller, bugmash, cache-control, patch
-
Rizwan Reza May 16th, 2010 @ 04:41 PM
- State changed from verified to open
-
pleax May 16th, 2010 @ 05:04 PM
@José Valim: As I can see, tests OdorcicD provided allready in master. And they pass :)
-
José Valim May 16th, 2010 @ 05:06 PM
- Tag changed from 2.3.x, actioncontroller, bugmash, cache-control, patch to 2.3.x, actioncontroller, cache-control, patch
- Assigned user set to José Valim
-
W. Andrew Loe III June 22nd, 2010 @ 07:58 PM
This will break downloads in IE over SSL.
http://support.microsoft.com/kb/323308
I ran into this when moving to 2.3.8, the headers changed from:
Cache-Control: private, max-age=0, must-revalidate <---- this works
to
Cache-Control: no-cache <--- this is broken.
-
José Valim June 23rd, 2010 @ 08:13 AM
- State changed from open to wontfix
Ok, closing. Since applying this on 2.3 (which is a maintenance branch) will definitely break apps for people relying on the wrong behavior
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>