Skip to content

Remove load_single_xblock from block_render.py #39434

Backlog

Description

@feanil

load_single_xblock in lms/djangoapps/courseware/block_render.py was the block loader for the xqueue_callback view. #39405 removes that view, and external grader scores already load the block through load_xblock_for_external_grader in lms/djangoapps/grades/score_render.py, so once it lands nothing in the platform calls load_single_xblock outside of tests. It also still tags every block it loads with grade_bucket_type='xqueue'.

Two callers are left:

We should move both callers off it and then remove the function. The xblocks-extra change has to land first, since that import would break on the release that drops it.

load_xblock_for_external_grader is not a drop-in replacement: it takes an anonymous user id and skips the access checks. The feedback filter probably wants get_block with a FieldDataCache directly, which is all load_single_xblock wraps.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions