Setup mockprock as a backend
Mockprock is a proctoring backend that runs as an HTTP server and a python module. It allows you to simulate the entire proctoring workflow.
To install it:
cd src
git clone git@github.com:edx/mockprock.git
cd ../devstack
make lms-shell
pip install -e /edx/src/mockprock
make studio-shell
pip install -e /edx/src/mockprock
Add it to your lms/envs/devstack.py
and studio/envs/devstack.py
:
NOTE: client_secret = client_id + 'secret'
PROCTORING_BACKENDS = {
'DEFAULT': 'mockprock',
'null': {},
'mockprock': {
'allow_honor_mode': True,
'client_id': 'abcd',
'client_secret': 'abcdsecret',
}
}
Rebuild static assets to make sure mockprock ui scripts are available:
make lms-static
Then back in your host shell:
cd ~/workspace/src/mockprock/
pip install -e .[server]
python -m mockprock.server
If you use Z shell (zsh), the command pip install -e .[server]
will fail with zsh: no matches found: .[server]
. This is because zsh uses square brackets for globbing/pattern matching. You should instead run the following command.:
pip install -e ".[server]"
The command will tell you you have to supply an client_id and client_secret. It'll open your browser to the Django admin page where you should create or use an existing credential.
You'll also need to add the user associated with the credential to the "mockprock_review" Django group. You can create the group at /admin/auth/group/
.
restart the server:
python -m mockprock.server abcd abcdsecret
If you need to run local changes to the mockprock Javascript worker or the worker interface in this library:
make lms-shell
(cd /edx/src/mockprock; npm link)
npm link @edx/mockprock
cd /edx/src/mockprock
(cd /edx/src/edx-proctoring; npm link)
npm link @edx/edx-proctoring
https://github.com/edx/edx-proctoring/blob/master/docs/developing.rst
2. Setup proctored exam for a course: https://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/latest/proctored_exams/proctored_enabling.html#enable-proctored-exams
appropriate course modes: VERIFIED, MASTERS, PROFESSIONAL, EXECUTIVE_EDUCATION, HONOR
add course mode. for your course (admin/course_modes/coursemode/add/):