def simple_paginate(request, queryset, per_page=20):
 p = paginator.SimplePaginator(queryset, per_page)
 page = p.page(request.GET.get('page', 1))
 page.url = build_paged_url(request)
 return page

def simple_paginate ( request , queryset , per_page = 20 ) : p = paginator . SimplePaginator ( queryset , per_page ) page = p . page ( request . GET . get ( 'page' , 1 ) ) page . url = build_paged_url ( request ) return page
get a simplepaginator page .