Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add proctorio redirect url #227

Merged
merged 1 commit into from
Dec 15, 2023
Merged

Conversation

zacharis278
Copy link
Contributor

@zacharis278 zacharis278 commented Dec 15, 2023

JIRA: COSMO-105

Description:

custom_url represents the url seen in the browser during an exam. When the extension is installed navigating to this URL will activate it and iframe in the exam content. By using a url we own we can handle what happens when the extension is not installed since the GET to /browser_lock will hit this service. If that happens we redirect the learner to getproctorio.com to install the extension.

The downside of this approach is getproctorio.com can't send the user back into the exam since we don't own that page. The learner would need to manually navigate back the the section and click start system check again.

To make this flow a bit smoother we would prefer learners download the extension first, before ever clicking 'start system check'. This ticket COSMO-130 adds that instruction to the interstitial. If they miss or ignore that instruction this PR will redirect them on the download page either way.

Note: We enforce the domain of messages from the extension. That will need to update along with this openedx/frontend-lib-special-exams#126

@@ -235,12 +235,12 @@ def start_proctoring(request, attempt_id):
lti_config = LtiConfiguration.objects.get(id=lti_config_id)

proctoring_start_assessment_url = urljoin(
get_lti_root(),
get_lti_api_base(),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this helper function already existed in the lti library. Removed a 'duplicate' util from this service

@@ -61,7 +61,10 @@ class ExamAttemptAdmin(admin.ModelAdmin):

def change_view(self, request, object_id, form_url='', extra_context=None):
extra_context = extra_context or {}
extra_context['LTI_ROOT'] = get_lti_root()
# technically this should be be using get_lti_view_base() but the
Copy link
Contributor Author

Choose a reason for hiding this comment

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

the customization on this django view can eventually be removed. It was only needed when we didn't have a UI to test with. I didn't want to add all that to this PR tho

@zacharis278 zacharis278 force-pushed the zhancock/custom-exam-url branch from 7fe9a94 to 97db843 Compare December 15, 2023 18:56
Copy link
Member

@alangsto alangsto left a comment

Choose a reason for hiding this comment

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

👍

@zacharis278 zacharis278 merged commit a6697a2 into main Dec 15, 2023
8 checks passed
@zacharis278 zacharis278 deleted the zhancock/custom-exam-url branch December 15, 2023 21:06
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