-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add xapi transformer for exam attempts events
fix: add attempt type for exam attempt events fix: add context data to event attempt events test: add fixtures for special exams refactor: use exam object for event attempts fix: add missing xapi concepts for exam events fix: use scorm pattern for exam events test: add fixtures for special exams fix: remove proctored and timed extensions fix: add duration extension fix: do not override get context extensions feat: include practice and proctored exam events fix: use attempt-id for attempt events test: add fixtures for proctored and practice exam events
- Loading branch information
Showing
20 changed files
with
746 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"id": "32e08e30-f8ae-4ce2-94a8-c2bfe38a70cb", "version": "1.0.3", "actor": {"objectType": "Agent", "account": {"name": "32e08e30-f8ae-4ce2-94a8-c2bfe38a70cb", "homePage": "http://localhost:18000"}}, "verb": {"id": "http://adlnet.gov/expapi/verbs/terminated", "display": {"en": "terminated"}}, "object": {"id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", "objectType": "Activity", "definition": {"name": {"en": "Subsection"}, "type": "https://w3id.org/xapi/openedx/activity/practice-assessment", "extensions": {"https://w3id.org/xapi/acrossx/extensions/time-limit": 60}}}, "timestamp": "2023-09-08T15:58:04.833393+00:00", "context": {"contextActivities": {"parent": [{"id": "http://localhost:18000/course/course-v1:edX+DemoX+Demo_Course", "objectType": "Activity", "definition": {"name": {"en-US": "Demonstration Course"}, "type": "http://adlnet.gov/expapi/activities/course"}}], "grouping": [{"id": "438AD672-DE2C-4F0B-8876-35444E7DD746", "objectType": "Activity", "definition": {"name": {"en": "Subsection"}, "type": "http://adlnet.gov/expapi/activities/attempt", "extensions": {"http://id.tincanapi.com/extension/attempt-id": 1}}}]}, "extensions": {"https://w3id.org/xapi/openedx/extension/transformer-version": "[email protected]", "https://w3id.org/xapi/openedx/extensions/session-id": "1c7862f091c5d7232ad3d7cf558f6e80"}}} |
This file contains 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
38 changes: 38 additions & 0 deletions
38
...backends/processors/tests/fixtures/current/edx.special_exam.practice.attempt.created.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "edx.special_exam.practice.attempt.created", | ||
"context": { | ||
"user_id": 3, | ||
"path": "/api/edx_proctoring/v1/proctored_exam/attempt", | ||
"course_id": "course-v1:edX+DemoX+Demo_Course", | ||
"org_id": "edX", | ||
"enterprise_uuid": "" | ||
}, | ||
"username": "student", | ||
"session": "1c7862f091c5d7232ad3d7cf558f6e80", | ||
"ip": "172.18.0.1", | ||
"agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36", | ||
"host": "localhost:18000", | ||
"referer": "http://localhost:18000", | ||
"accept_language": "en-US,en;q=0.9", | ||
"event": { | ||
"exam_id": 1, | ||
"exam_content_id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", | ||
"exam_name": "Subsection", | ||
"exam_default_time_limit_mins": 60, | ||
"exam_is_proctored": false, | ||
"exam_is_practice_exam": true, | ||
"exam_is_active": true, | ||
"attempt_id": 1, | ||
"attempt_user_id": 3, | ||
"attempt_started_at": null, | ||
"attempt_completed_at": null, | ||
"attempt_code": "438AD672-DE2C-4F0B-8876-35444E7DD746", | ||
"attempt_allowed_time_limit_mins": null, | ||
"attempt_status": "created", | ||
"attempt_event_elapsed_time_secs": null | ||
}, | ||
"time": "2023-09-08T15:58:04.833393+00:00", | ||
"event_type": "edx.special_exam.timed.attempt.created", | ||
"event_source": "server", | ||
"page": null | ||
} |
38 changes: 38 additions & 0 deletions
38
...ckends/processors/tests/fixtures/current/edx.special_exam.practice.attempt.submitted.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "edx.special_exam.practice.attempt.submitted", | ||
"context": { | ||
"user_id": 3, | ||
"path": "/api/edx_proctoring/v1/proctored_exam/attempt/1", | ||
"course_id": "course-v1:edX+DemoX+Demo_Course", | ||
"org_id": "edX", | ||
"enterprise_uuid": "" | ||
}, | ||
"username": "student", | ||
"session": "1c7862f091c5d7232ad3d7cf558f6e80", | ||
"ip": "172.18.0.1", | ||
"agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36", | ||
"host": "localhost:18000", | ||
"referer": "http://localhost:18000", | ||
"accept_language": "en-US,en;q=0.9", | ||
"event": { | ||
"exam_id": 1, | ||
"exam_content_id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", | ||
"exam_name": "Subsection", | ||
"exam_default_time_limit_mins": 60, | ||
"exam_is_proctored": false, | ||
"exam_is_practice_exam": true, | ||
"exam_is_active": true, | ||
"attempt_id": 1, | ||
"attempt_user_id": 3, | ||
"attempt_started_at": "2023-09-08T15:58:04.838598+00:00", | ||
"attempt_completed_at": "2023-09-08T16:20:53.577698+00:00", | ||
"attempt_code": "438AD672-DE2C-4F0B-8876-35444E7DD746", | ||
"attempt_allowed_time_limit_mins": 60, | ||
"attempt_status": "submitted", | ||
"attempt_event_elapsed_time_secs": 1368.7657 | ||
}, | ||
"time": "2023-09-08T16:20:53.604375+00:00", | ||
"event_type": "edx.special_exam.timed.attempt.submitted", | ||
"event_source": "server", | ||
"page": null | ||
} |
38 changes: 38 additions & 0 deletions
38
...ackends/processors/tests/fixtures/current/edx.special_exam.proctored.attempt.created.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "edx.special_exam.proctored.attempt.created", | ||
"context": { | ||
"user_id": 3, | ||
"path": "/api/edx_proctoring/v1/proctored_exam/attempt", | ||
"course_id": "course-v1:edX+DemoX+Demo_Course", | ||
"org_id": "edX", | ||
"enterprise_uuid": "" | ||
}, | ||
"username": "student", | ||
"session": "1c7862f091c5d7232ad3d7cf558f6e80", | ||
"ip": "172.18.0.1", | ||
"agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36", | ||
"host": "localhost:18000", | ||
"referer": "http://localhost:18000", | ||
"accept_language": "en-US,en;q=0.9", | ||
"event": { | ||
"exam_id": 1, | ||
"exam_content_id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", | ||
"exam_name": "Subsection", | ||
"exam_default_time_limit_mins": 60, | ||
"exam_is_proctored": true, | ||
"exam_is_practice_exam": false, | ||
"exam_is_active": true, | ||
"attempt_id": 1, | ||
"attempt_user_id": 3, | ||
"attempt_started_at": null, | ||
"attempt_completed_at": null, | ||
"attempt_code": "438AD672-DE2C-4F0B-8876-35444E7DD746", | ||
"attempt_allowed_time_limit_mins": null, | ||
"attempt_status": "created", | ||
"attempt_event_elapsed_time_secs": null | ||
}, | ||
"time": "2023-09-08T15:58:04.833393+00:00", | ||
"event_type": "edx.special_exam.timed.attempt.created", | ||
"event_source": "server", | ||
"page": null | ||
} |
38 changes: 38 additions & 0 deletions
38
...kends/processors/tests/fixtures/current/edx.special_exam.proctored.attempt.submitted.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "edx.special_exam.proctored.attempt.submitted", | ||
"context": { | ||
"user_id": 3, | ||
"path": "/api/edx_proctoring/v1/proctored_exam/attempt/1", | ||
"course_id": "course-v1:edX+DemoX+Demo_Course", | ||
"org_id": "edX", | ||
"enterprise_uuid": "" | ||
}, | ||
"username": "student", | ||
"session": "1c7862f091c5d7232ad3d7cf558f6e80", | ||
"ip": "172.18.0.1", | ||
"agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36", | ||
"host": "localhost:18000", | ||
"referer": "http://localhost:18000", | ||
"accept_language": "en-US,en;q=0.9", | ||
"event": { | ||
"exam_id": 1, | ||
"exam_content_id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", | ||
"exam_name": "Subsection", | ||
"exam_default_time_limit_mins": 60, | ||
"exam_is_proctored": true, | ||
"exam_is_practice_exam": false, | ||
"exam_is_active": true, | ||
"attempt_id": 1, | ||
"attempt_user_id": 3, | ||
"attempt_started_at": "2023-09-08T15:58:04.838598+00:00", | ||
"attempt_completed_at": "2023-09-08T16:20:53.577698+00:00", | ||
"attempt_code": "438AD672-DE2C-4F0B-8876-35444E7DD746", | ||
"attempt_allowed_time_limit_mins": 60, | ||
"attempt_status": "submitted", | ||
"attempt_event_elapsed_time_secs": 1368.7657 | ||
}, | ||
"time": "2023-09-08T16:20:53.604375+00:00", | ||
"event_type": "edx.special_exam.timed.attempt.submitted", | ||
"event_source": "server", | ||
"page": null | ||
} |
38 changes: 38 additions & 0 deletions
38
...ng_backends/processors/tests/fixtures/current/edx.special_exam.timed.attempt.created.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "edx.special_exam.timed.attempt.created", | ||
"context": { | ||
"user_id": 3, | ||
"path": "/api/edx_proctoring/v1/proctored_exam/attempt", | ||
"course_id": "course-v1:edX+DemoX+Demo_Course", | ||
"org_id": "edX", | ||
"enterprise_uuid": "" | ||
}, | ||
"username": "student", | ||
"session": "1c7862f091c5d7232ad3d7cf558f6e80", | ||
"ip": "172.18.0.1", | ||
"agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36", | ||
"host": "localhost:18000", | ||
"referer": "http://localhost:18000", | ||
"accept_language": "en-US,en;q=0.9", | ||
"event": { | ||
"exam_id": 1, | ||
"exam_content_id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", | ||
"exam_name": "Subsection", | ||
"exam_default_time_limit_mins": 60, | ||
"exam_is_proctored": false, | ||
"exam_is_practice_exam": false, | ||
"exam_is_active": true, | ||
"attempt_id": 1, | ||
"attempt_user_id": 3, | ||
"attempt_started_at": null, | ||
"attempt_completed_at": null, | ||
"attempt_code": "438AD672-DE2C-4F0B-8876-35444E7DD746", | ||
"attempt_allowed_time_limit_mins": null, | ||
"attempt_status": "created", | ||
"attempt_event_elapsed_time_secs": null | ||
}, | ||
"time": "2023-09-08T15:58:04.833393+00:00", | ||
"event_type": "edx.special_exam.timed.attempt.created", | ||
"event_source": "server", | ||
"page": null | ||
} |
38 changes: 38 additions & 0 deletions
38
..._backends/processors/tests/fixtures/current/edx.special_exam.timed.attempt.submitted.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "edx.special_exam.timed.attempt.submitted", | ||
"context": { | ||
"user_id": 3, | ||
"path": "/api/edx_proctoring/v1/proctored_exam/attempt/1", | ||
"course_id": "course-v1:edX+DemoX+Demo_Course", | ||
"org_id": "edX", | ||
"enterprise_uuid": "" | ||
}, | ||
"username": "student", | ||
"session": "1c7862f091c5d7232ad3d7cf558f6e80", | ||
"ip": "172.18.0.1", | ||
"agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36", | ||
"host": "localhost:18000", | ||
"referer": "http://localhost:18000", | ||
"accept_language": "en-US,en;q=0.9", | ||
"event": { | ||
"exam_id": 1, | ||
"exam_content_id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@5b4bf8d7d41c4070b299abefed74155e", | ||
"exam_name": "Subsection", | ||
"exam_default_time_limit_mins": 60, | ||
"exam_is_proctored": false, | ||
"exam_is_practice_exam": false, | ||
"exam_is_active": true, | ||
"attempt_id": 1, | ||
"attempt_user_id": 3, | ||
"attempt_started_at": "2023-09-08T15:58:04.838598+00:00", | ||
"attempt_completed_at": "2023-09-08T16:20:53.577698+00:00", | ||
"attempt_code": "438AD672-DE2C-4F0B-8876-35444E7DD746", | ||
"attempt_allowed_time_limit_mins": 60, | ||
"attempt_status": "submitted", | ||
"attempt_event_elapsed_time_secs": 1368.7657 | ||
}, | ||
"time": "2023-09-08T16:20:53.604375+00:00", | ||
"event_type": "edx.special_exam.timed.attempt.submitted", | ||
"event_source": "server", | ||
"page": null | ||
} |
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.