diff --git a/jobstreet/jst_ph_search.py b/jobstreet/jst_ph_search.py index 261dfd8..9fa40fe 100644 --- a/jobstreet/jst_ph_search.py +++ b/jobstreet/jst_ph_search.py @@ -10,7 +10,7 @@ def write_to_file(searchfilename, json_data): s_id_wr = DictWriter(s_id, fieldnames=column) if s_id.tell() == 0: s_id_wr.writeheader() - print(json_data) + # print(json_data) # input() writeable_data = { "jobid" : json_data.get('id'), @@ -47,6 +47,7 @@ def ph_search(searchfilename): } while current_page<= total_pages : + print(f'{current_page} of {total_pages}) query_params = { "siteKey": "PH-Main", "sourcesystem": "houston", @@ -68,6 +69,7 @@ def ph_search(searchfilename): total_pages = ceil(response.json()['totalCount']/100) for each_job in response.json()['data']: write_to_file( searchfilename, each_job) + current_page +=1 else: print("Request failed with status code:", response.status_code)