Skip to content

Conversation

@jansenk
Copy link
Member

@jansenk jansenk commented Jan 7, 2026

Add functionality for the learning sequence course outline endpoint to be able to return audit preview information, which can be done by simply checking the existing helper function and passing it through get_user_course_outline_details to _get_user_course_outline_and_processors

Copilot AI review requested due to automatic review settings January 7, 2026 21:06
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds audit preview functionality to the learning sequence course outline endpoint, allowing audit learners to see (but not access) verified-only content when the feature is enabled. The implementation leverages existing preview logic by passing the preview_verified_content flag through the API chain.

  • Adds preview_verified_content parameter to get_user_course_outline_details function
  • Updates the view to check if audit preview is enabled via learner_can_preview_verified_content toggle
  • Includes previewable field in sequence serialization to indicate which sequences are previewable

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.

File Description
openedx/core/djangoapps/content/learning_sequences/views.py Imports the audit preview toggle function, passes preview flag to API, and adds previewable field to sequence representation
openedx/core/djangoapps/content/learning_sequences/api/outlines.py Adds preview_verified_content parameter to get_user_course_outline_details and passes it through to the helper function
openedx/core/djangoapps/content/learning_sequences/tests/test_views.py Adds comprehensive test suite for audit preview feature with test cases covering verified students, audit students with preview enabled, and audit students with preview disabled

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings January 7, 2026 21:25
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants