Opened 9 years ago

Closed 9 years ago

#4421 closed (invalid)

Caching documentation reports that cache_page takes two arguments.

Reported by: kris.kowal@… Owned by: jacob
Component: Documentation Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


Toward the middle of the page, we see this line of code:

slashdot_this = cache_page(slashdot_this, 60 * 15)

That the statements "cache_page takes one argument" and "subscribes to Python's decorator notation" would be more consistent with this line of code:

slashdot_this = cache_page(60 * 15)(slashdot_this)

Change History (1)

comment:1 Changed 9 years ago by Gary Wilson <gary.wilson@…>

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to invalid
  • Status changed from new to closed

The problem is that cache_page does not adhere to Python's decorator notation, see #1015. Also, the cache_page decorator should be able to take more than a single argument (it should be able to take all the arguments that the CacheMiddleware's constructor takes since the decorator is created from the CacheMiddleware class).

Note: See TracTickets for help on using tickets.
Back to Top