Workaround for aiorun triggering stackoverflow in Python #88
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Under certain circumstances this line
aiorun/aiorun.py
Line 297 in 6023e9c
aiorun
can trigger the following Python bug python/cpython#93837The program will crash with a stack overflow error, probably because the call to log the task about the be cancelled will call repr on a task that references itself somehow.
While its not the greatest fix to remove the logging of the individual task to be cancelled (as suggested by this PR), it is just a small inconvenience compared to a hard crash of the application. (I also tried to just log
t.get_name()
, however this was not enough)