Message164433
Davide, the @contextlib.contextmanager decorator effectively wraps the
yield statement in the necessary glue so that everything prior to the yield
statement occurs in the __enter__() method of the contextmanager, while
everything subsequent occurs in the __exit__() method.
On Sat, Jun 30, 2012 at 1:46 AM, Davide Rizzo <report@bugs.python.org>wrote:
>
> Davide Rizzo <sorcio@gmail.com> added the comment:
>
> Daniel, Nick, shouldn't the context manager yield f within a with block?
>
> ----------
> nosy: +davide.rizzo
>
> _______________________________________
> Python tracker <report@bugs.python.org>
> <http://bugs.python.org/issue14243>
> _______________________________________
> |
|
Date |
User |
Action |
Args |
2012-06-30 23:01:53 | dlenski | set | recipients:
+ dlenski, jaraco, ncoghlan, pitrou, eric.smith, tim.golden, eric.araujo, r.david.murray, brian.curtin, dabrahams, davide.rizzo, sbt |
2012-06-30 23:01:52 | dlenski | link | issue14243 messages |
2012-06-30 23:01:52 | dlenski | create | |
|