-
-
Notifications
You must be signed in to change notification settings - Fork 332
-
-
Notifications
You must be signed in to change notification settings - Fork 332
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
run_fn_as_system_task does not account for nested Trio #2191
Comments
This was referenced Jan 25, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm new to Trio, so forgive me if I get the terminology wrong. This check for deadlock only checks if there is a Trio task at all, not that the task is the same as the caller. So, if we have something like this:
It will fail and exit the portal prematurely because
endpoint
is running in Trio, but the portal is a different Trio task. The check sees if there's a task at all, rather than checking if the call would actually deadlock the task in the case of nesting.If I remove the current task check, the portal runs successfully with no deadlock.
The text was updated successfully, but these errors were encountered: