Skip to content

Instantly share code, notes, and snippets.

View elcolie's full-sized avatar

El 李天宝 elcolie

View GitHub Profile
from django.db import connection, reset_queries
import time
import functools
def query_debugger(func):
@functools.wraps(func)
def inner_func(*args, **kwargs):
reset_queries()