Skip to content

[Edge Case] TC-00128 SGA: Grades stick in "Awaiting instructor approval" when Instructor grades while masquerading as Learner/Audit #559

@abdullah8590

Description

@abdullah8590

Bug Priority: Low (Edge Case)
Component: Staff Graded Assignment (SGA) XBlock

Description
When an instructor attempts to grade a Staff Graded Assignment while the LMS "View this course as" feature is set to "Specific Learner" or "Audit" track, the grade is not successfully committed as a final staff grade.

Instead of finalizing the grade, the system saves the input but tags it with "(Awaiting instructor approval)". This suggests that the masquerade context is interfering with the is_staff or permission check during the save operation, causing the system to treat the action as lacking full instructor authority.

Preconditions
A course exists with an edx_sga (Staff Graded Assignment) component.
A learner has submitted a file for this assignment.
User is logged in as Instructor/Staff.

Steps to Reproduce

  1. Navigate to the Courseware (Live View) where the SGA component is located.
  2. In the Instructor toolbar (top of page), use the "View this course as" dropdown.
  3. Select "Specific Learner" (and enter a username) or select "Audit".
  4. Scroll down to the SGA component.
  5. Click "Grade Submissions" (or the interface button to view the grading modal).
  6. Locate a learner's submission and enter a grade (e.g., 100).
  7. Submit/Save the grade.

Actual Result
The grade appears in the table, but is followed by the status text: "100 / 100 (Awaiting instructor approval)".
The grade is not published to the learner's progress.

Expected Result
The system should detect that the actual user is Staff, even if masquerading, and process the grade as a final, approved instructor grade.

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions