Omnibus commited on
Commit
a2b5996
1 Parent(s): e7786c5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -90,7 +90,7 @@ def run_script(url: str, height: int, width: int, check_b,check_h):
90
  out = f'comb-{uid}-tmp.png'
91
  screenshot = obj.screenshot(f'{uid}-tmp.png')
92
  except WebDriverException as e:
93
- return Image.new('RGB', (1, 1)), f'<center>{e}',out_box,out
94
  finally:
95
  if driver:
96
  driver.quit()
@@ -119,4 +119,4 @@ with gr.Blocks() as app:
119
  outim = gr.Image()
120
 
121
  btn.click(run_script,[inp,height,width,check_b,check_h],[outim,message,outgal,out])
122
- app.launch()
 
90
  out = f'comb-{uid}-tmp.png'
91
  screenshot = obj.screenshot(f'{uid}-tmp.png')
92
  except WebDriverException as e:
93
+ return Image.new('RGB', (1, 1)), f'<center>Please enter a valid URL of a website/host.',out_box,out
94
  finally:
95
  if driver:
96
  driver.quit()
 
119
  outim = gr.Image()
120
 
121
  btn.click(run_script,[inp,height,width,check_b,check_h],[outim,message,outgal,out])
122
+ app.queue(default_concurrency_limit=5).launch()