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

Use non-blocking zmq Poller #1023

Merged
merged 4 commits into from
May 23, 2024
Merged

Use non-blocking zmq Poller #1023

merged 4 commits into from
May 23, 2024

Conversation

fcollonval
Copy link
Contributor

Fixes #1022

Copy link
Member

@davidbrochart davidbrochart left a comment

Choose a reason for hiding this comment

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

Failures are unrelated, see #1024.

@ianthomas23
Copy link
Contributor

Pinning pytest<8.2 helps with the test failures.

Copy link
Member

@minrk minrk left a comment

Choose a reason for hiding this comment

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

👍 to the headline Poller-related change, but the unrelated get_msg type change isn't right, I think.

@@ -220,7 +220,7 @@ def _recv(self, **kwargs: t.Any) -> t.Dict[str, t.Any]:
ident, smsg = self.session.feed_identities(msg)
return self.session.deserialize(smsg)

def get_msg(self, timeout: t.Optional[float] = None) -> t.Dict[str, t.Any]:
def get_msg(self, timeout: t.Optional[int] = None) -> t.Dict[str, t.Any]:
Copy link
Member

Choose a reason for hiding this comment

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

This should accept a float. get_msg(timeout=0.25) is valid. The cast to int should happen after multiplying by 1000 to get ms.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the review @minrk

I corrected it in 733bd59 (applying the same changes for the async case that was not flagged).

@fcollonval fcollonval requested a review from minrk May 15, 2024 08:29
@krassowski
Copy link
Member

It would be great to see this released :) Is the timeout in one of the Windows tests related?

@davidbrochart
Copy link
Member

I don't think it's related. I'd like to merge but I cannot bypass the rules. Maybe @blink1073 can help?

@blink1073 blink1073 merged commit 474093f into jupyter:main May 23, 2024
29 of 32 checks passed
@fcollonval fcollonval deleted the patch-3 branch May 23, 2024 06:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

zmq.Poller is not async
6 participants