Fix get_assignments and get_course_members for courses with sections #45
+15
−4
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Fixes
get_assignments
andget_course_members
for courses with sections. Sections Management documentation from Gradescope.Details
Courses with sections changes the UI in a couple ways.
Rosters page has a new
sections
column. This column is not visible if a course does not have sections. Currently, the logic breaks as it expects thenum_submissions
column in index3
but it is actually index4
if a course has sections.Sections
is in the header. If it is, offset thenum_submissions
column index by 1. Note: this is pretty brittle as it relies on string matching so languages other thanEnglish
will probably break. Looked at some HTML classes/ids but there didn't seem to be a good way to target the section header. Possibly check thearia
accessibility tags instead.Assignments can be selectively released (visible/hidden) to specific sections. This changes the assignments table by adding a drop-down with statues for each section.
Checks
Reference to the issue
This should resolve #44 but more extensive testing with courses with and without sections is probably needed.