Please sign in to comment.
Simplify StackContext logic and behavior.
Previously, there was an optimization to avoid recreating contexts that were already on the stack. This optimization rarely mattered (especially given the movement to run all callbacks through IOLoop.add_callback), and sometimes caused surprising behavior as other exception handlers could be inserted between stack contexts that expected to be adjacent to each other or to the wrapped function. Now each wrapped function recreates its full stack of contexts, even if some of those contexts were already on the stack. This change allows a use of NullContext in testing.py to be removed.
- Loading branch information...
Showing with 9 additions and 31 deletions.