awacke1 commited on
Commit
c92c73a
·
1 Parent(s): 931aeda

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -2
app.py CHANGED
@@ -396,8 +396,12 @@ def get_zip_download_link(zip_file):
396
  return href
397
 
398
  def whisper(filename):
399
- with open(filename, "rb") as f:
400
- data = f.read
 
 
 
 
401
  #try:
402
  response = requests.post(WHISPER_API_URL, headers=WHISPER_headers, data=data)
403
  #except:
 
396
  return href
397
 
398
  def whisper(filename):
399
+ try:
400
+ with open(filename, "rb") as f:
401
+ data = f.read
402
+ st.write(data)
403
+ except:
404
+ st.write(f'Could not open or read {filename}')
405
  #try:
406
  response = requests.post(WHISPER_API_URL, headers=WHISPER_headers, data=data)
407
  #except: