datacipen commited on
Commit
6983e17
1 Parent(s): 44f2f2c

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +3 -1
main.py CHANGED
@@ -718,7 +718,9 @@ async def API_France_Travail(romeListArray):
718
  end_dt = datetime.datetime.today()
719
  results = []
720
  for k in romeListArray:
721
- params = {"motsCles": k,'minCreationDate': dt_to_str_iso(start_dt),'maxCreationDate': dt_to_str_iso(end_dt),'range':'0-149'}
 
 
722
  try:
723
  search_on_big_data = client.search(params=params)
724
  results += search_on_big_data["resultats"]
 
718
  end_dt = datetime.datetime.today()
719
  results = []
720
  for k in romeListArray:
721
+ if k[0:1] == ' ':
722
+ k = k[1:]
723
+ params = {"motsCles": k.replace(',','').replace(' ',','),'minCreationDate': dt_to_str_iso(start_dt),'maxCreationDate': dt_to_str_iso(end_dt),'range':'0-149'}
724
  try:
725
  search_on_big_data = client.search(params=params)
726
  results += search_on_big_data["resultats"]