On 12/14/07, djnz <[EMAIL PROTECTED]> wrote: > > > Thanks for your reply. So It could be an issue of my configuration or > code. But What? > My project runs perfect on trunk. I am trying to migrate to the > newforms-admin branch, so i made the required changes in the code as > described in the documentation. I know is very strange, but yes, I > modify a record with admin and click in save and continue editing.The > changes does not display but If I look at the record with pgadmin III > or similar the changes were made. > > I have to run the server on windows and linux with similar results. > ..... > .... > Uffff. I have found the problem. I have removed the > 'django.middleware.cache.CacheMiddleware' and now it works. Although i > dont undestand why becouse i didn't have any configuration of the > CACHE_MIDDLEWARE in settings and it worked on trunk. :?
Well, enabling the CacheMiddleware caches your entire site: http://www.djangoproject.com/documentation/cache/#the-per-site-cache (Though the doc says you need to also set the required parameters CACHE_MIDDLEWARE_SECONDS and CACHE_MIDDLEWARE_KEY_PREFIX, this doesn't seem to be the case...when I have no CACHE_* settings in settings.py, and simply enable the cache middleware, my entire site starts being cached.) I can confirm the behavior for the admin site is different on newforms-admin vs. trunk (both tested this morning using r6898) when the CacheMiddleware is enabled. With trunk, admin pages don't appear to be cached -- when I make a change I see the effect immediately on the admin pages (though not on my own site pages, since they are being cached -- they take 10 minutes or so to time out and reflect new values). With newforms-admin, the admin pages now appear to also be included in the per-site cache. If I bring up an admin change page and change a value, then press "Save and continue editing", the value reverts to what had originally been displayed. I have to move on to a different admin page to see the message about the value being successfully changed. This behavior seems odd but reading the doc it also seems to be technically correct...there's even a note in there that setting CACHE_MIDDLEWARE_ANONYMOUS_ONLY to True is a way to disable caching of the admin pages. Since I don't have that set, it sounds like caching of admin pages is expected. Only they don't seem to be cached on trunk, even without the CACHE_MIDDLEWARE_ANONYMOUS_ONLY set to True. I don't know why that is, but it seems that the trunk behavior is what doesn't match the docs. Karen --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" 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-users?hl=en -~----------~----~----~----~------~----~------~--~---

