Code

Opened 8 years ago

Closed 8 years ago

Last modified 7 years ago

#2744 closed defect (fixed)

context processors cant return None cause it not checked in RequestContext

Reported by: anonymous Owned by: adrian
Component: Template system Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

this just came up in irc when someone did return None instead of a dict

Attachments (1)

context-processor-returns-none.patch (470 bytes) - added by anonymous 8 years ago.
my patch to fix it

Download all attachments as: .zip

Change History (3)

Changed 8 years ago by anonymous

my patch to fix it

comment:1 Changed 8 years ago by ubernostrum

Hmm.

I'm not sure if we should do this, or if we should make it extra-clear in the documentation that context processors must return a dictionary -- even if it's an empty dictionary.

comment:2 Changed 8 years ago by adrian

  • Resolution set to fixed
  • Status changed from new to closed

(In [3865]) Fixed #2744 -- Added 'Writing your own context processors' to docs/templates_python.txt

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.