-
Notifications
You must be signed in to change notification settings - Fork 341
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
StdoutLock not released on drop. #640
Comments
I'm noticing something similar with some mutexes at the moment. I'll see if I can post some sample code tomorrow to reproduce my issue. It looks like mutexes don't relinquish locks, even when I make the calls to |
Thus in scenario above unlocking will fail (silently or with panic, depending |
@tmiasko Does anything similar apply to |
@tmiasko could you perhaps share more on this? |
Typically a mutex can be unlocked only by the owner, i.e., thread that locked it. The |
Interesting. This could be pretty confusing and counter-intuitive behavior for many people. Are there any plans to address this sort of behavior within async-std? I'm assuming fixing this would require changes to the task scheduler, at the very least. |
@Noah-Kennedy from talking with @stjepang in a call yesterday, we're considering maybe dropping this range of APIs all together. The new scheduler outlined in #631 would help with any (potentially) slow IO. There are probably ways of writing true async |
@yoshuawuyts which APIs would be dropped? |
I could see the new scheduler allowing those to be removed, with people just using the |
@Noah-Kennedy just stdout/stdin/stderr; our async mutex impl actually has distinct benefits compared to always blocking threads. |
This causes a deadlock with 1.4.0 :
The text was updated successfully, but these errors were encountered: