-
10kviews5Wrap any iterable context manager so it closes when consumedscorePython / contextmanager, context_manager, generator, iterable, iterator, with_statement / by Andrew Barnert (11 years ago)
-
10kviews2Decorator and context manager from a single APIscorePython / contextmanager, context_manager, decorator, decorators, with, with_statement / by Michael Foord (13 years ago, revision 12)