Skip to content

Commit cc28cf2

Browse files
committed
fix: issues with socket hanging
1 parent bd95809 commit cc28cf2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

easyecs/helpers/common.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ def convert_containers_to_dict(containers):
5959

6060
def is_port_in_use(port: int) -> bool:
6161
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
62+
s.settimeout(0.5)
6263
try:
6364
s.connect(("127.0.0.1", int(port)))
6465
s.shutdown(2)

0 commit comments

Comments
 (0)