#6552: django.core.context_processors.auth causes "Vary: Cookie" header no
matter
what
-------------------------------------+--------------------------------------
Reporter: [email protected] | Owner: lukeplant
Status: reopened | Milestone:
Component: Authentication | Version: SVN
Resolution: | Keywords:
Stage: Accepted | Has_patch: 1
Needs_docs: 1 | Needs_tests: 0
Needs_better_patch: 0 |
-------------------------------------+--------------------------------------
Changes (by intrepidweb):
* status: closed => reopened
* resolution: fixed =>
Comment:
Hi -- I am not sure if this is related, but I want to report it in case. I
recently had a problem with the Vary:Cookie header unexpectedly being
added to my responses. I scoured my code for unintentional accessing of
the session. I couldn't find anything. Eventually through testing I
pinpointed the auth context processor
(django.contrib.auth.context_processors.auth) as the source of the
problem. My temporary fix was to comment out the 'messages' assignment in
the dict returned by the processor. That did the trick; now the
Vary:Cookie header is only being added when the session is indeed
accessed. Any ideas of what's going on? Should get_messages perhaps be
lazily accessed, just like get_user?
--
Ticket URL: <http://code.djangoproject.com/ticket/6552#comment:21>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.