Skip to content

Instantly share code, notes, and snippets.

@fission6
Last active December 8, 2016 19:05
Show Gist options
  • Save fission6/16280f489d834c760ca3df9af01c6a52 to your computer and use it in GitHub Desktop.
Save fission6/16280f489d834c760ca3df9af01c6a52 to your computer and use it in GitHub Desktop.
def orders_report(request, company):
import cProfile
pr = cProfile.Profile()
pr.enable()
....code to profile
# stop profiling and output to console
pr.disable()
pr.print_stats(sort='time')
return resp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment