Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bind(self=xxx) fails #14

Open
rbtcollins opened this issue Jul 9, 2015 · 0 comments
Open

bind(self=xxx) fails #14

rbtcollins opened this issue Jul 9, 2015 · 0 comments

Comments

@rbtcollins
Copy link

I have a method like so:

class F:
def f(a, self):
pass

signature(partial(F.f, None)).bind(self=10)

fails, due to receiving self too many times.

The function bind() can't be defined with self as its own parameter - it conflicts with binds that pass self in. Instead it needs to take _args, *_kwargs, and pull self out of args[0].

I'll throw up a patch in alittle, for now (in mock), I'm monkeypatching to fix it.

rbtcollins added a commit to rbtcollins/funcsigs that referenced this issue Jul 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant