lms.djangoapps.grades.management.commands package#
Submodules#
lms.djangoapps.grades.management.commands.compute_grades module#
Command to compute all grades for specified courses.
- class lms.djangoapps.grades.management.commands.compute_grades.Command(stdout=None, stderr=None, no_color=False, force_color=False)#
Bases:
BaseCommand- Example usage:
$ ./manage.py lms compute_grades –all_courses –settings=devstack $ ./manage.py lms compute_grades ‘edX/DemoX/Demo_Course’ –settings=devstack
- add_arguments(parser)#
Entry point for subclassed commands to add custom arguments.
- args = '<course_id course_id ...>'#
- enqueue_all_shuffled_tasks(options)#
Enqueue all tasks, in shuffled order.
- handle(*args, **options)#
The actual logic of the command. Subclasses must implement this method.
- help = 'Computes grade values for all learners in specified courses.'#
lms.djangoapps.grades.management.commands.recalculate_learner_grades module#
Command to recalculate a user’s grades for a course, for every user in a csv of (user, course) pairs.
- class lms.djangoapps.grades.management.commands.recalculate_learner_grades.Command(stdout=None, stderr=None, no_color=False, force_color=False)#
Bases:
BaseCommand- Example usage:
$ ./manage.py lms recalculate_learner_grades learner_courses_to_recalculate.csv
- add_arguments(parser)#
Entry point for subclassed commands to add custom arguments.
- handle(*args, **options)#
The actual logic of the command. Subclasses must implement this method.
- help = "Recalculates a user's grades for a course, for every user in a csv of (user, course) pairs"#
- regrade_learner_in_course_from_csv(csv_file)#
lms.djangoapps.grades.management.commands.recalculate_subsection_grades module#
Command to recalculate grades for all subsections with problem submissions in the specified time range.
- class lms.djangoapps.grades.management.commands.recalculate_subsection_grades.Command(stdout=None, stderr=None, no_color=False, force_color=False)#
Bases:
BaseCommand- Example usage:
- $ ./manage.py lms recalculate_subsection_grades
–modified_start ‘2016-08-23 16:43’ –modified_end ‘2016-08-25 16:43’ –settings=devstack
- add_arguments(parser)#
Entry point for subclassed commands to add custom arguments.
- args = 'fill this in'#
- handle(*args, **options)#
The actual logic of the command. Subclasses must implement this method.
- help = 'Recalculates subsection grades for all subsections modified within the given time range.'#
lms.djangoapps.grades.management.commands.send_segment_events_for_failed_learners module#
Send segment events for failed learners.
- class lms.djangoapps.grades.management.commands.send_segment_events_for_failed_learners.Command(stdout=None, stderr=None, no_color=False, force_color=False)#
Bases:
BaseCommand- Example usage:
$ ./manage.py lms send_segment_events_for_failed_learners
- add_arguments(parser)#
Entry point to add arguments.
- get_courses()#
Find all courses where end date has passed 31 days ago course grade override date is course.end + 30 days but we are adding grace period of 1 day to mitigate any edge cases due to last minute grade override.
- get_failed_enrollment_and_user_ids(course)#
Get list of all the enrolled users that failed the given course. This method will only consider paid enrolments.
- Parameters:
course (CourseOverview) – Course overview instance whose failed enrolments should be returned.
- Returns:
An iterator with paginated user ids, each iteration will return 500 item list of user ids.
- Return type:
(generator)
- handle(*args, **options)#
Command’s entery point.
- help = 'Send segment events for failed learners.'#