feat: add CourseModePriceRequested filter#376
Open
kiram15 wants to merge 1 commit into
Open
Conversation
kiram15
commented
Jul 7, 2026
|
|
||
| Arguments: | ||
| block (VerticalBlock): The VeriticalBlock instance which is being rendered. | ||
| block (VerticalBlock): The VerticalBlock instance which is being rendered. |
Contributor
Author
There was a problem hiding this comment.
Unrelated spelling change
There was a problem hiding this comment.
Pull request overview
Adds a new public filter to the openedx_filters.learning subdomain for determining the price a learner should be charged for a selected course mode, along with a basic passthrough test to validate default behavior when no pipeline is configured.
Changes:
- Added
CourseModePriceRequestedfilter (org.openedx.learning.course_mode.price.requested.v1) with arun_filter(user, course_mode_data, price)API. - Added a unit test verifying the filter returns the original inputs when no pipeline is configured.
- Fixed minor typos in an existing VerticalBlock-related docstring.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| openedx_filters/learning/filters.py | Introduces the new CourseModePriceRequested filter and corrects a docstring typo elsewhere in the module. |
| openedx_filters/learning/tests/test_filters.py | Adds a new test case covering the default passthrough behavior for the new filter. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
pwnage101
requested changes
Jul 7, 2026
pwnage101
left a comment
Contributor
There was a problem hiding this comment.
besides the minor assertion issue, this also still needs a version bump & changelog entry
00790b6 to
998c09f
Compare
998c09f to
4049968
Compare
pwnage101
reviewed
Jul 9, 2026
4049968 to
025a230
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
This new filter determines the price a learner should be charged based upon their course mode. It has two related PRs that show the full implementation and how it is tested (see below).
This ticket is split from #338, please reference for previous PR comments.
Supporting information
https://2u-internal.atlassian.net/browse/ENT-11573
edx/edx-platform#365
openedx/edx-enterprise#2556
Testing instructions
Testing instruction in the edx-enterprise PR!
Checklists
Check off if complete or not applicable:
Merge Checklist:
Post Merge: