Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Performance Demo [no --revocation] #2151

Merged
merged 1 commit into from
Feb 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions demo/runners/performance.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,15 @@ async def check_received_creds(self) -> Tuple[int, int]:
pending = 0
total = len(self.credential_state)
for result in self.credential_state.values():
if result != "done" and result != "credential_acked":
# Since cred_ex_record is set to be auto-removed
# the state in self.credential_state for completed
# exchanges will be deleted. Any problematic
# exchanges will be in abandoned state.
if (
result != "done"
and result != "deleted"
and result != "credential_acked"
):
pending += 1
if self.credential_event.is_set():
continue
Expand Down Expand Up @@ -422,7 +430,7 @@ async def check_received_creds(agent, issue_count, pb):
pending, total = await agent.check_received_creds()
complete = total - pending
if reported == complete:
await asyncio.wait_for(agent.update_creds(), 30)
await asyncio.wait_for(agent.update_creds(), 45)
continue
if iter_pb and complete > reported:
try:
Expand Down
2 changes: 1 addition & 1 deletion demo/runners/support/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -724,7 +724,7 @@ def _terminate(self):
if self.proc and self.proc.poll() is None:
self.proc.terminate()
try:
self.proc.wait(timeout=0.5)
self.proc.wait(timeout=1.5)
self.log(f"Exited with return code {self.proc.returncode}")
except subprocess.TimeoutExpired:
msg = "Process did not terminate in time"
Expand Down