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

Check if the current thread is the io thread #884

Merged
merged 1 commit into from Mar 22, 2022

Conversation

jamadeo
Copy link
Contributor

@jamadeo jamadeo commented Mar 22, 2022

I noticed that I'll somewhat unpredictably run into this issue where the kernel prints "IOStream.flush timed out". I found that OutStream.flush() could be called in the I/O thread itself, leading to a wait() that will block for the full 10 second timeout.

I can't reliably reproduce an instance of flush() getting called in the I/O thread, but in my case it looked like a logger.warning call inside the asyncio event loop handling was responsible for it.

I think this could be the issue in #334 ?

@blink1073 blink1073 added the bug label Mar 22, 2022
Copy link
Member

@blink1073 blink1073 left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@blink1073 blink1073 merged commit 268984f into ipython:main Mar 22, 2022
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.

None yet

2 participants