Course Blocks API: Fix handling of incorrectly-cased course keys (#25911)
Commit 7f59688f attempted to solve this using `CourseOverview.course_exists`, but that check is case- insensitive. This commit instead does a small refactor to `lms.djangoapps.courseware.get_course` so that we can handle a failed course lookup without broadly catching a `ValueError`.
Showing
- lms/djangoapps/bulk_email/tests/test_err_handling.py 2 additions, 2 deletionslms/djangoapps/bulk_email/tests/test_err_handling.py
- lms/djangoapps/course_api/blocks/permissions.py 4 additions, 2 deletionslms/djangoapps/course_api/blocks/permissions.py
- lms/djangoapps/courseware/courses.py 3 additions, 2 deletionslms/djangoapps/courseware/courses.py
- lms/djangoapps/courseware/exceptions.py 16 additions, 0 deletionslms/djangoapps/courseware/exceptions.py
Please register or sign in to comment