Skip to content

Commit

Permalink
TMP: debug CI
Browse files Browse the repository at this point in the history
  • Loading branch information
darosior committed May 11, 2022
1 parent 5091018 commit daa2f85
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ task:
name: 'Functional tests'
container:
image: rust:latest
timeout_in: 90m # https://cirrus-ci.org/faq/#instance-timed-out

env:
EXECUTOR_WORKERS: 1
EXECUTOR_WORKERS: 10
VERBOSE: 1
LOG_LEVEL: debug
TIMEOUT: 300
Expand Down
11 changes: 9 additions & 2 deletions tests/test_framework/coordinatord.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def __init__(
self.s.bind(("localhost", self.port))
self.s.listen(1_000)
# The server socket is set to nonblocking to stop immediately on shutdown
self.s.setblocking(False)
# self.s.setblocking(False)
self.r_close_chann, self.w_close_chann = os.pipe()

# A mapping from txid to pubkey to signature
Expand Down Expand Up @@ -169,9 +169,16 @@ def run(self):
if self.r_close_chann in r_fds:
break
if self.s.fileno() in r_fds:
t = threading.Thread(target=self.connection_handle, daemon=True)
t = threading.Thread(target=self.a, daemon=True)
t.start()

def a(self):
try:
self.connection_handle()
except Exception as e:
logging.error(e)
raise e

def connection_handle(self):
"""Read and treat requests from this client. Blocking."""
client_fd, _ = self.s.accept()
Expand Down

0 comments on commit daa2f85

Please sign in to comment.