Omnibus commited on
Commit
1201acd
·
verified ·
1 Parent(s): 8d5f479

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -314,11 +314,14 @@ def load_data():
314
  r = requests.get(f'{save_data}{f_ist[0]}')
315
  lod = json.loads(r.text)
316
  timestamp=str(datetime.datetime.now())
317
- filename=f_ist[0].split("/")[1].split(".json")[0]
318
  print (filename)
319
- filename = filename.replace("--"," ").replace("-"[3],":").replace("-"[3],":").replace("-"[3],".")
 
 
 
320
  print (filename)
321
- yield lod,[(None,f'Source is current as of:\n{timename} UTC\n\nThe current Date and Time is:\n{timestamp} UTC')]
322
 
323
  with gr.Blocks() as app:
324
  cb = gr.Chatbot(height=500)
 
314
  r = requests.get(f'{save_data}{f_ist[0]}')
315
  lod = json.loads(r.text)
316
  timestamp=str(datetime.datetime.now())
317
+ filename=f_ist[0].split("/")[1].split(".json")[0].replace("--"," ")
318
  print (filename)
319
+ filename_start = filename.split(" ")[0]
320
+ filename_end = filename.split(" ")[1]
321
+ filename_end = filename_end.replace("-"[0],":").replace("-"[0],":").replace("-"[0],".")
322
+ #filename_end_far=filename_end.split(":")[2]
323
  print (filename)
324
+ yield lod,[(None,f'Source is current as of:\n{filename_start} {filename_end} UTC\n\nThe current Date and Time is:\n{timestamp} UTC')]
325
 
326
  with gr.Blocks() as app:
327
  cb = gr.Chatbot(height=500)