diff --git a/jobstreet/jst_malay_detail.py b/jobstreet/jst_malay_detail.py index df31795..2c23b5a 100644 --- a/jobstreet/jst_malay_detail.py +++ b/jobstreet/jst_malay_detail.py @@ -67,13 +67,13 @@ def jstMalayJobDetailScraper(search_file, jd_file): # print(response.text) if response.status_code == 200: - print("yes 200") + # print("yes 200") result = response.json() # print("result", result) if jfile.tell() == 0: j_writer.writeheader() if result.get('data', {'jobDetail' :''}).get('jobDetail'): - print(result.get('data', {'jobDetail' :''}).get('jobDetail')) + # print(result.get('data', {'jobDetail' :''}).get('jobDetail')) # print(result['data']['jobDetail']) try : job_industry = result['data']['jobDetail']\ diff --git a/jobstreet/jst_malay_search.py b/jobstreet/jst_malay_search.py index d802653..05f013f 100644 --- a/jobstreet/jst_malay_search.py +++ b/jobstreet/jst_malay_search.py @@ -58,12 +58,12 @@ def search_jst_malay(csv_file): total_pages = ceil(result['data']['jobs']['totalJobs']/30) if len(result['data']['jobs']['jobs']) > 0 : column = ['Company_Name'] + list(result['data']['jobs']['jobs'][0].keys())[:6] - print("writing to file") + # print("writing to file") with open(csv_file, 'a+', newline='', encoding='utf-8') as csvfile: writer = DictWriter(csvfile, fieldnames=column, extrasaction='ignore') if csvfile.tell() == 0: writer.writeheader() - print("writing each array") + # print("writing each array") for a_job in result['data']['jobs']['jobs']: a_job['Company_Name'] = a_job['companyMeta']['name'] writer.writerow(a_job) diff --git a/jobstreet/jst_ph_search.py b/jobstreet/jst_ph_search.py index c0ef43a..e2290da 100644 --- a/jobstreet/jst_ph_search.py +++ b/jobstreet/jst_ph_search.py @@ -66,7 +66,7 @@ def ph_search(searchfilename): response = requests.get(base_url, params=query_params, headers=headers, timeout=20) if response.status_code == 200: - print("Request was successful") + # print("Request was successful") total_pages = ceil(response.json()['totalCount']/100) for each_job in response.json()['data']: write_to_file( searchfilename, each_job) diff --git a/jobstreet/jst_sg_detail.py b/jobstreet/jst_sg_detail.py index 67597e3..63ae7bd 100644 --- a/jobstreet/jst_sg_detail.py +++ b/jobstreet/jst_sg_detail.py @@ -67,13 +67,13 @@ def jstMalayJobDetailScraper(search_file, jd_file): # print(response.text) if response.status_code == 200: - print("yes 200") + # print("yes 200") result = response.json() # print("result", result) if jfile.tell() == 0: j_writer.writeheader() if result.get('data', {'jobDetail' :''}).get('jobDetail'): - print(result.get('data', {'jobDetail' :''}).get('jobDetail')) + # print(result.get('data', {'jobDetail' :''}).get('jobDetail')) # print(result['data']['jobDetail']) try : job_industry = result['data']['jobDetail']\ diff --git a/jobstreet/jst_sg_search.py b/jobstreet/jst_sg_search.py index 26862de..9e1aa22 100644 --- a/jobstreet/jst_sg_search.py +++ b/jobstreet/jst_sg_search.py @@ -58,12 +58,12 @@ def search_jst_malay(csv_file): total_pages = ceil(result['data']['jobs']['totalJobs']/30) if len(result['data']['jobs']['jobs']) > 0 : column = ['Company_Name'] + list(result['data']['jobs']['jobs'][0].keys())[:6] - print("writing to file") + # print("writing to file") with open(csv_file, 'a+', newline='', encoding='utf-8') as csvfile: writer = DictWriter(csvfile, fieldnames=column, extrasaction='ignore') if csvfile.tell() == 0: writer.writeheader() - print("writing each array") + # print("writing each array") for a_job in result['data']['jobs']['jobs']: a_job['Company_Name'] = a_job['companyMeta']['name'] writer.writerow(a_job)