Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

[MCKIN-9474] [BB-873] Support for filters, and multiple roots in problem response reports - #1378

Merged
xitij2000 merged 1 commit into
developmentfrom
kshitij/enhanced-xblocks-reporting-solutions
Feb 20, 2019
Merged

xitij2000 merged 1 commit into
developmentfrom
kshitij/enhanced-xblocks-reporting-solutions

Conversation

@xitij2000

Copy link
Copy Markdown

This PR adds two features to the problem response report API:

  1. Support for specifying multiple root blocks.
    With this feature, you can now pass a comma-separated list of problem locations, and the generated report will include both of them (and children).

  2. Support for specifying a problem type filter.
    This feature allows you to request a report for only one or more types of problems.

Re: https://github.com/edx/edx-platform/pull/19781

@xitij2000
xitij2000 force-pushed the kshitij/enhanced-xblocks-reporting-solutions branch 3 times, most recently from 46099ee to 0465983 Compare February 19, 2019 07:56
@xitij2000
xitij2000 force-pushed the kshitij/enhanced-xblocks-reporting-solutions branch from 0465983 to 5099b35 Compare February 19, 2019 10:39
@edx edx deleted a comment from openedx-webhooks Feb 19, 2019

@giovannicimolin giovannicimolin left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

👍

  • I tested this:
  1. I used the EdX Demo Course as base for testing this.
  2. Generate problem response reports for 2 problems sending comma-separated values.
  3. Checked that the report was correctly generated and responses for both problems were included ✔️
  4. Used section block-v1:edX+DemoX+Demo_Course+type@chapter+block@graded_interactions and tested the problem_types_filter with three values:
  • openassessment
  • problem
  • openassessment,problem
  1. Checked that the generated reports contained only the problems that were specified on each operation ✔️
  2. Checked that we can generate a problem response report for the entire course with block-v1:edX+DemoX+Demo_Course+type@course+block@course
  • I read through the code
  • Includes documentation: on the docstrings
  • I checked for accessibility issues NA

Nice work! This is ready to merge. 😁

To make testing this easier, I logged in LMS on Chrome, generated a problem response report and copied a cURL request that looked like this:

curl 'http://lms.mcka.local/api/instructor/v1/course/course-v1:edX+DemoX+Demo_Course/reports/problem_responses' -H 'Pragma: no-cache' -H 'Origin: http://lms.mcka.local' -H 'Accept-Encoding: gzip, deflate' -H 'Accept-Language: en-US,en;q=0.9' -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.96 Safari/537.36' -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' -H 'Accept: application/json, text/javascript, */*; q=0.01' -H 'Cache-Control: no-cache' -H 'X-Requested-With: XMLHttpRequest' -H 'Cookie: openedx-language-preference=en; djdt=hide; csrftoken=nYvaNAd0020JjeC5B86H26T2mS2dKnMQ; sessionid=7czmuk4ij6r5c0ka3xitl5dbeql8mvmf' -H 'Connection: keep-alive' -H 'X-CSRFToken: nYvaNAd0020JjeC5B86H26T2mS2dKnMQ' -H 'Referer: http://lms.mcka.local/courses/course-v1:edX+DemoX+Demo_Course/instructor' --data 'problem_location=block-v1%3AedX%2BDemoX%2BDemo_Course%2Btype%40chapter%2Bblock%40graded_interactions' --compressed

" To view the status of the report, see Pending Tasks below."
)
return JsonResponse({"status": success_status})
return JsonResponse({"status": success_status, "task_id": task.task_id})

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Nice job 😁

@xitij2000 xitij2000 changed the title BB-873: Support for filters, and multiple roots in problem response reports [MCKIN-9474] BB-873: Support for filters, and multiple roots in problem response reports Feb 20, 2019
@xitij2000 xitij2000 changed the title [MCKIN-9474] BB-873: Support for filters, and multiple roots in problem response reports [MCKIN-9474] [BB-873] Support for filters, and multiple roots in problem response reports Feb 20, 2019
@xitij2000
xitij2000 merged commit 5b838ed into development Feb 20, 2019
@xitij2000
xitij2000 deleted the kshitij/enhanced-xblocks-reporting-solutions branch February 20, 2019 09:28
xitij2000 added a commit that referenced this pull request Mar 19, 2019
…report generation (#1378)

[MCKIN-9474] [BB-873] Support for filters, and multiple roots in problem response reports
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants