@transaction.non_atomic_requests
@require_POST
@ensure_csrf_cookie
@cache_control(no_cache=True, no_store=True, must_revalidate=True)
@require_level('staff')
def problem_grade_report(request, course_id):
 course_key = SlashSeparatedCourseKey.from_deprecated_string(course_id)
 try:
  lms.djangoapps.instructor_task.api.submit_problem_grade_report(request, course_key)
  success_status = _('The problem grade report is being created. To view the status of the report, see Pending Tasks below.')
  return JsonResponse({'status': success_status})
 except AlreadyRunningError:
  already_running_status = _('A problem grade report is already being generated. To view the status of the report, see Pending Tasks below. You will be able to download the report when it is complete.')
  return JsonResponse({'status': already_running_status})

@ transaction . non_atomic_requests @ require_POST @ ensure_csrf_cookie @ cache_control ( no_cache = True , no_store = True , must_revalidate = True ) @ require_level ( 'staff' ) def problem_grade_report ( request , course_id ) : course_key = SlashSeparatedCourseKey . from_deprecated_string ( course_id ) try : lms . djangoapps . instructor_task . api . submit_problem_grade_report ( request , course_key ) success_status = _ ( 'The problem grade report is being created. To view the status of the report, see Pending Tasks below.' ) return JsonResponse ( { 'status' : success_status } ) except AlreadyRunningError : already_running_status = _ ( 'A problem grade report is already being generated. To view the status of the report, see Pending Tasks below. You will be able to download the report when it is complete.' ) return JsonResponse ( { 'status' : already_running_status } )
request a csv showing students grades for all problems in the course .