easymode.debug

Tools for debugging python applications

easymode.debug.stack_trace(depth=None)

returns a print friendly stack trace at the current frame, without aborting the application.

Parameters:depth – The depth of the stack trace. if omitted, the entire stack will be printed.

usage:

print stack_trace(10)

easymode.debug.middleware

Replacements for django middlewares that allow you to see what is put in to the cache and comes out of the cache.

class easymode.debug.middleware.DebugCacheMiddleware(cache_timeout=None, key_prefix=None, cache_anonymous_only=None)

combines DebugFetchFromCacheMiddleware and easymode.debug.middleware.DebugUpdateCacheMiddleware

class easymode.debug.middleware.DebugFetchFromCacheMiddleware

Same as FetchFromCacheMiddleware but it shows you what it is retrieving from the cache if it can find something.

process_request(request)

Checks whether the page is already cached and returns the cached version if available.

class easymode.debug.middleware.DebugUpdateCacheMiddleware

Same as UpdateCacheMiddleware but is shows you when something is put into the cache.

process_response(request, response)

Sets the cache, if needed.

Table Of Contents

Previous topic

easymode.admin.utils