no sadface at all. check what we're evaling; actually really cool


On 27 March 2014 15:47, Fergus Doyle <notifications@github.com> wrote:

> In nameko/dependencies.py:
>
> > @@ -355,6 +359,15 @@ def registering_decorator(wrapper, fn, args, kwargs):
> >                                        'DependencyFactory instances')
> >          register_entrypoint(fn, factory)
> >          wrapper.provider_cls = factory.dep_cls
> > +
> > +        regargs, varargs, varkwargs, defaults = inspect.getargspec(fn)
> > +        regargs = regargs[1:]  # remove 'self'
> > +        signature = inspect.formatargspec(
> > +            regargs, varargs, varkwargs, defaults, formatvalue=lambda val: "")
> > +
> > +        src = "lambda %s: None" % signature[1:-1]
> > +        fn.shadow = eval(src)
> > +
>
> we have evals in here? [image: :disappointed:]
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/onefinestay/nameko/pull/119/files#r11029073>
> .
>



-- 

David Szotten

onefinestay


david.szotten@onefinestay.com


300 St John Street
London, EC1V 4PA