[openstack-dev] [nova] contextlib.nested and Python3 failing

Joshua Harlow harlowja at outlook.com
Wed Aug 26 01:44:50 UTC 2015


On Tue, 25 Aug 2015 12:23:28 -0700
Jay Pipes <jaypipes at gmail.com> wrote:

> On 08/25/2015 10:17 AM, Joshua Harlow wrote:
> > Oh, discard everything I say then :)
> >
> > My brain must still be partially functioning due to vacation,
> > haha.  
> 
> import functools
> 
> def work(vacation=False):
>      if not vacation:
>          get_lots_done()
> 
> back_from_vacation = functools.partial(work, vacation=True)
> 
> There you go, Josh. There's your partial function.
> 
> Best,
> -jay

I approve of this message, ha.

:)



More information about the OpenStack-dev mailing list