This is my view:
def post_detail(request, year, month, day, slug):
post = get_object_or_404(models.Post, slug=slug, status='published',
publish__year=year, publish__month=month,
publish__day=day)
comment_form = forms.CommentForm()
comments = post.comments.filter(active=True)
context = {
'comments': comments,
'post': post,
'comment_form': comment_form,
}
return render(request, 'blog/post_detail.html', context)
Is there any way to calculate time of execution in Django ?