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
container_commands: | |
01_makemigrations: | |
command: "python manage.py makemigrations" | |
leader_only: true | |
02_migrate: | |
command: "python manage.py migrate" | |
leader_only: true | |
# Patch the current version, circular imports cause an ImportError (see https://github.com/Koed00/django-q/issues/331) | |
03_patch_django_q: | |
# Replace line 12 ('from django_q.cluster import worker, monitor') by 'from django_q.cluster import *' |
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
import json | |
import pandas as pd | |
# Input: Zoho JSON response as a string - Output : {'First Name': 'John', 'Last Name': 'Doe', 'Phone': ... } | |
# To be used like a generator (i.e `for candidate in parse_json_iter(zoho_response):`) | |
# `get_fields` allows you to specify fields to get, the others will be dismissed. | |
# `module` = 'Candidates', 'JobOpenings'... (haven't tried with others) | |
def parse_json_iter(raw_json_response: str, module: str = 'Candidates', get_fields: list = []): | |
"""Parse through a JSON response of candidates.""" |