bstraehle commited on
Commit
04a6068
·
verified ·
1 Parent(s): d96270e

Update utils.py

Browse files
Files changed (1) hide show
  1. utils.py +6 -1
utils.py CHANGED
@@ -24,13 +24,18 @@ def read_file_json(file_path):
24
 
25
  df = None
26
 
 
27
  if is_ext(file_path, "csv"):
28
  df = pd.read_csv(file_path)
 
29
  elif is_ext(file_path, "xls") or is_ext(file_path, "xlsx"):
30
  df = pd.read_excel(file_path)
 
31
  elif is_ext(file_path, "json") or is_ext(file_path, "jsonl"):
32
  df = pd.read_json(file_path)
33
-
 
 
34
  return "" if df is None else df.to_json()
35
 
36
  def read_docx_text(file_path):
 
24
 
25
  df = None
26
 
27
+ print("111")
28
  if is_ext(file_path, "csv"):
29
  df = pd.read_csv(file_path)
30
+ print("csv")
31
  elif is_ext(file_path, "xls") or is_ext(file_path, "xlsx"):
32
  df = pd.read_excel(file_path)
33
+ print("xls")
34
  elif is_ext(file_path, "json") or is_ext(file_path, "jsonl"):
35
  df = pd.read_json(file_path)
36
+ print("json")
37
+ print("222")
38
+
39
  return "" if df is None else df.to_json()
40
 
41
  def read_docx_text(file_path):