Skip to content

Conversation

@Connor-Bernard
Copy link
Member

-- Copying from previous GV repo on behalf of @yhwli --

API v2 for Progress Report - JSON URL parameter
### Note: URL Parameter "class" is changed to "course" to maintain naming accuracy and consistency.

Usage:

Path: /

URL Parameters:
    school
    course
    student_mastery
    class_mastery

Path: /json

Content-Type: application/json
Data:
{
  "school": "Berkeley",
  "course": "CS10",
  "student_mastery": {
      "Abstraction": 4,
      "Number Representation": 4,
      "Iteration": 3,
      "Domain and Range": 4,
      "Booleans": 1,
      "Functions": 0,
      "HOFs I": 0
  },
  "class_mastery": {
      "Abstraction": 1,
      "Number Representation": 1,
      "Iteration": 1,
      "Domain and Range": 1,
      "Booleans": 1,
      "Functions": 0,
      "HOFs I": 0
  }

Copy link
Member Author

@Connor-Bernard Connor-Bernard left a comment

Choose a reason for hiding this comment

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

[REQUIRED CHANGE]

def parse_json_mastery(school_name, course_name, student_mastery_json, class_mastery_json):
def assign_node_levels_json(node, student_levels_count, class_levels_count):
nonlocal student_mastery, class_mastery
if not node["children"]:
Copy link
Member Author

Choose a reason for hiding this comment

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

Revise this to remove side effects and just return the student and class mastery

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.

3 participants