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

feat: add timeout to controller.py #56

Merged

Conversation

anwalker293
Copy link
Contributor

@anwalker293 anwalker293 commented Aug 28, 2023

Requested from Daniel ~

Original Post:
Re: timeouts, we would need to adjust the timeouts on the record_with_value calls which is actually happening in the protocols methods we're calling, I think. We'd need to update the acapy-minimal-example controller to allow us to set a default timeout.

[event.payload.get(key) == value for key, value in values.items()]
)
event = await asyncio.wait_for(
self.event_queue.get(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is really close! As it turns out, the event_queue.get method takes a timeout parameter so we can use that instead of the asyncio.wait_for in this method. (Under the hood, this is exactly what the event_queue.get method is doing so the methodology is good!)

@anwalker293
Copy link
Contributor Author

Subtle note: The get method forces it to be a int. We can either change this or leave it be, let me know! :)

@dbluhm
Copy link
Member

dbluhm commented Aug 29, 2023

LGTM!

@dbluhm dbluhm merged commit 5165962 into Indicio-tech:main Aug 29, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants