Skip to content

Custom Context Processors executed twice #353

@ghost

Description

Hi, not sure if this has been an issue in the past but when I am using a custom context processor that is executed from TEMPLATE_CONTEXT_PROCESSORS, I get the issue where the context processor is being executed twice.

At first I thought it was an issue with the logging so I ignored it until I saw duplicate entries being written to the remote database so it seems it actually was executing the entire context processor for my app twice according to the logs.

This occurs when using render() in my views, since it already includes RequestContext(request) and all other context processors data is being executed from the settings declaration. If I use render_to_response() and omit the use of RequestContext(request) it does not execute twice.

I am able to continue using the render() return on the views with my custom context processors executing only one time by excluding 'debug_toolbar.panels.template.TemplateDebugPanel' from settings although this is not an actual fix

I thought I might bring this to some attention. I am using django-debug-toolbar-0.9.4 and Django 1.4.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions