diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 7e02c2bb..eb99896f 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -201,6 +201,10 @@ Fixed * ``DELETE /api/authz/v1/roles/users/`` no longer lets a user remove its own ``library_admin`` or ``course_admin`` role, matching the admin console. The user is reported in ``errors`` with ``cannot_remove_own_admin_role`` and keeps the role; other users in the request are processed. +* The hidden ``course_limited_staff`` role now grants the Instructor Dashboard permissions that match + its legacy access to the Course Info, Enrollments, Grading and Cohorts tabs, so the dashboard no + longer denies it access to them. It does not get bulk learner grading, learner extensions or course + team permissions. Run ``load_authz_schema`` to apply the new grants. 1.24.0 - 2026-09-14 ******************* diff --git a/docs/references/compiled-schema.yaml b/docs/references/compiled-schema.yaml index de08ab63..f969de4e 100644 --- a/docs/references/compiled-schema.yaml +++ b/docs/references/compiled-schema.yaml @@ -139,8 +139,22 @@ roles: icon: null hidden: true permissions: + course_authoring: + - courses.view_grading_settings course_team_roles: - courses.legacy_limited_staff_role_permissions + enrollments: + - courses.enroll_learners + - courses.unenroll_learners + - courses.view_enrollments + learner_administration: + - courses.manage_cohorts + - courses.view_cohorts + - courses.view_course_info + - courses.view_learner_course_status + learner_grading: + - courses.manage_learner_grading + - courses.view_gradebook course_staff: display_name: Course Staff description: Can publish content and manage the course lifecycle in Studio. diff --git a/src/openedx_authz/applets/course_authoring/README.rst b/src/openedx_authz/applets/course_authoring/README.rst index c932afc6..fb71fb00 100644 --- a/src/openedx_authz/applets/course_authoring/README.rst +++ b/src/openedx_authz/applets/course_authoring/README.rst @@ -1,6 +1,6 @@ Course Authoring ################ -This applet owns the existing built-in permissions for authoring, configuring, and managing the team of a course. It adds those permissions to the shared course-team roles through role extensions, while the role identifiers and metadata remain in ``course_team_roles``. ``constants.py`` contains its permission objects. +This applet owns the existing built-in permissions for authoring, configuring, and managing the team of a course. It adds those permissions to the shared course-team roles through role extensions, while the role identifiers and metadata remain in ``course_team_roles``. The hidden ``course_limited_staff`` role only gets ``courses.view_grading_settings``, for the Grading tab of the Instructor Dashboard. ``constants.py`` contains its permission objects. The applet is an internal package, so clients import these constants from ``openedx_authz.authz``. The existing ``openedx_authz.constants.permissions`` path remains a compatibility export. diff --git a/src/openedx_authz/applets/course_authoring/schema/role_extensions.yaml b/src/openedx_authz/applets/course_authoring/schema/role_extensions.yaml index 29b35790..7fc8576b 100644 --- a/src/openedx_authz/applets/course_authoring/schema/role_extensions.yaml +++ b/src/openedx_authz/applets/course_authoring/schema/role_extensions.yaml @@ -109,3 +109,7 @@ role_extensions: - courses.view_certificates - courses.view_group_configurations - courses.view_library_updates + + - role_id: course_limited_staff + add_permissions: + - courses.view_grading_settings diff --git a/src/openedx_authz/applets/enrollments/README.rst b/src/openedx_authz/applets/enrollments/README.rst index f123a9ea..5ac2bc1d 100644 --- a/src/openedx_authz/applets/enrollments/README.rst +++ b/src/openedx_authz/applets/enrollments/README.rst @@ -1,6 +1,6 @@ Enrollments ########### -This applet owns the permissions for viewing course enrollments and for enrolling or unenrolling learners, which belong to the Content Access / Enrollments bounded context. It adds those permissions to the ``course_admin`` and ``course_staff`` roles through role extensions. ``constants.py`` contains its permission objects. +This applet owns the permissions for viewing course enrollments and for enrolling or unenrolling learners, which belong to the Content Access / Enrollments bounded context. It adds those permissions to the ``course_admin`` and ``course_staff`` roles through role extensions. It also adds them to the hidden ``course_limited_staff`` role. ``constants.py`` contains its permission objects. The applet is an internal package, so clients import these constants from ``openedx_authz.authz``. The existing ``openedx_authz.constants.permissions`` path remains a compatibility export. diff --git a/src/openedx_authz/applets/enrollments/schema/role_extensions.yaml b/src/openedx_authz/applets/enrollments/schema/role_extensions.yaml index 7fad3712..8443e06f 100644 --- a/src/openedx_authz/applets/enrollments/schema/role_extensions.yaml +++ b/src/openedx_authz/applets/enrollments/schema/role_extensions.yaml @@ -13,3 +13,9 @@ role_extensions: - courses.view_enrollments - courses.enroll_learners - courses.unenroll_learners + + - role_id: course_limited_staff + add_permissions: + - courses.view_enrollments + - courses.enroll_learners + - courses.unenroll_learners diff --git a/src/openedx_authz/applets/learner_administration/README.rst b/src/openedx_authz/applets/learner_administration/README.rst index 48895c3c..1cc1dc28 100644 --- a/src/openedx_authz/applets/learner_administration/README.rst +++ b/src/openedx_authz/applets/learner_administration/README.rst @@ -1,6 +1,6 @@ Learner Administration ###################### -This applet owns the permissions for viewing course information and a learner's course status, and managing learner extensions and cohorts, which belong to the Support Learning bounded context. It adds those permissions to the ``course_admin`` and ``course_staff`` roles through role extensions. ``constants.py`` contains its permission objects. +This applet owns the permissions for viewing course information and a learner's course status, and managing learner extensions and cohorts, which belong to the Support Learning bounded context. It adds those permissions to the ``course_admin`` and ``course_staff`` roles through role extensions. It also adds the ones matching the legacy limited staff access to the hidden ``course_limited_staff`` role. ``constants.py`` contains its permission objects. The applet is an internal package, so clients import these constants from ``openedx_authz.authz``. The existing ``openedx_authz.constants.permissions`` path remains a compatibility export. diff --git a/src/openedx_authz/applets/learner_administration/schema/role_extensions.yaml b/src/openedx_authz/applets/learner_administration/schema/role_extensions.yaml index 78d4dead..f99d184f 100644 --- a/src/openedx_authz/applets/learner_administration/schema/role_extensions.yaml +++ b/src/openedx_authz/applets/learner_administration/schema/role_extensions.yaml @@ -19,3 +19,10 @@ role_extensions: - courses.manage_learner_extensions - courses.view_cohorts - courses.manage_cohorts + + - role_id: course_limited_staff + add_permissions: + - courses.view_course_info + - courses.view_learner_course_status + - courses.view_cohorts + - courses.manage_cohorts diff --git a/src/openedx_authz/applets/learner_grading/README.rst b/src/openedx_authz/applets/learner_grading/README.rst index 0d0c69df..2f2e29ed 100644 --- a/src/openedx_authz/applets/learner_grading/README.rst +++ b/src/openedx_authz/applets/learner_grading/README.rst @@ -1,6 +1,6 @@ Learner Grading ############### -This applet owns the permissions for viewing the gradebook and using grading tools for individual learners or all learners, which belong to the Consuming Learning Content bounded context. It adds those permissions to the ``course_admin`` and ``course_staff`` roles through role extensions. ``constants.py`` contains its permission objects. +This applet owns the permissions for viewing the gradebook and using grading tools for individual learners or all learners, which belong to the Consuming Learning Content bounded context. It adds those permissions to the ``course_admin`` and ``course_staff`` roles through role extensions. It also adds the ones matching the legacy limited staff access to the hidden ``course_limited_staff`` role. ``constants.py`` contains its permission objects. The applet is an internal package, so clients import these constants from ``openedx_authz.authz``. The existing ``openedx_authz.constants.permissions`` path remains a compatibility export. diff --git a/src/openedx_authz/applets/learner_grading/schema/role_extensions.yaml b/src/openedx_authz/applets/learner_grading/schema/role_extensions.yaml index a732cd1c..a6b3ff41 100644 --- a/src/openedx_authz/applets/learner_grading/schema/role_extensions.yaml +++ b/src/openedx_authz/applets/learner_grading/schema/role_extensions.yaml @@ -12,3 +12,8 @@ role_extensions: add_permissions: - courses.view_gradebook - courses.manage_learner_grading + + - role_id: course_limited_staff + add_permissions: + - courses.view_gradebook + - courses.manage_learner_grading diff --git a/src/openedx_authz/tests/role_permissions.py b/src/openedx_authz/tests/role_permissions.py index e189fd1a..8edde094 100644 --- a/src/openedx_authz/tests/role_permissions.py +++ b/src/openedx_authz/tests/role_permissions.py @@ -173,6 +173,16 @@ COURSE_LIMITED_STAFF_PERMISSIONS = [ COURSES_LEGACY_LIMITED_STAFF_ROLE_PERMISSIONS, + COURSES_VIEW_ENROLLMENTS, + COURSES_ENROLL_LEARNERS, + COURSES_UNENROLL_LEARNERS, + COURSES_VIEW_GRADEBOOK, + COURSES_MANAGE_LEARNER_GRADING, + COURSES_VIEW_COURSE_INFO, + COURSES_VIEW_LEARNER_COURSE_STATUS, + COURSES_VIEW_COHORTS, + COURSES_MANAGE_COHORTS, + COURSES_VIEW_GRADING_SETTINGS, ] COURSE_DATA_RESEARCHER_PERMISSIONS = [