osamabyc86 commited on
Commit
83e1962
·
verified ·
1 Parent(s): 90f91f0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -92,7 +92,7 @@ def _connect_until_success():
92
  node_id = os.getenv("NODE_ID", socket.gethostname())
93
  ip = _get_local_ip(pd)
94
  print(f"🔎 Trying server: {server}")
95
-
96
  any_attempt = False
97
  for p in _sequential_ports(pd):
98
  any_attempt = True
@@ -120,6 +120,9 @@ def _connect_until_success():
120
  def start_connect_loop():
121
  threading.Thread(target=_connect_until_success, daemon=True).start()
122
 
 
 
 
123
  # مسار اختبار سريع
124
  @app.get("/")
125
  def hello():
 
92
  node_id = os.getenv("NODE_ID", socket.gethostname())
93
  ip = _get_local_ip(pd)
94
  print(f"🔎 Trying server: {server}")
95
+ print("🚀 Started connection attempt loop")
96
  any_attempt = False
97
  for p in _sequential_ports(pd):
98
  any_attempt = True
 
120
  def start_connect_loop():
121
  threading.Thread(target=_connect_until_success, daemon=True).start()
122
 
123
+ print("🌀 Launching connection thread") # ← أضف هنا أيضًا
124
+ threading.Thread(target=_connect_until_success, daemon=True).start()
125
+
126
  # مسار اختبار سريع
127
  @app.get("/")
128
  def hello():