BlakeL commited on
Commit
db5b0d1
·
verified ·
1 Parent(s): 6b4a12d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -15
app.py CHANGED
@@ -683,22 +683,22 @@ if __name__ == "__main__":
683
  app = create_interface()
684
 
685
  # Launch with automatic port finding
686
- import socket
687
- def find_free_port():
688
- with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s:
689
- s.bind(('', 0))
690
- s.listen(1)
691
- port = s.getsockname()[1]
692
- return port
693
 
694
- port = find_free_port()
695
- print(f"🚀 Launching app on port {port}")
696
- print(f"📱 Access the app at: http://localhost:{port}")
697
 
698
  app.launch(
699
- server_name="0.0.0.0",
700
- server_port=port,
701
- share=False,
702
- show_error=True,
703
- quiet=False
704
  )
 
683
  app = create_interface()
684
 
685
  # Launch with automatic port finding
686
+ # import socket
687
+ # def find_free_port():
688
+ # with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s:
689
+ # s.bind(('', 0))
690
+ # s.listen(1)
691
+ # port = s.getsockname()[1]
692
+ # return port
693
 
694
+ # port = find_free_port()
695
+ # print(f"🚀 Launching app on port {port}")
696
+ # print(f"📱 Access the app at: http://localhost:{port}")
697
 
698
  app.launch(
699
+ # server_name="0.0.0.0",
700
+ # server_port=port,
701
+ # share=False,
702
+ # show_error=True,
703
+ # quiet=False
704
  )