Dave Jones

Results 127 comments of Dave Jones

@lurch - what the `_wrap_callback` test is looking for is whether the function accepts a _mandatory_ parameter. If it's happy to be called with no parameters, we assume that's fine...

I'm going to start in an odd order here, to keep my reply vaguely coherent, sorry about the jumping around! From @Marrin > Reasons for implementing something in C include...

> functools.partial() comes from the builtin _functools module, i.e. written in C and compiled into the CPython interpreter binary. It is not written in Python. At least not on the...

> EDIT: Although the above doesn't work if you have a partial wrapping a partial (you get TypeError: is not a Python function), so perhaps partial-function support would need some...

Better to fix _wrap_callback in a manner similar to @lurch's suggestion to properly handle wrapped stuff. Shouldn't be too hard - I've just pushed something to my clone which ought...

Just going to add some docs and tests, then I'll PR it

Damn, so close! Unfortunately I'm tied up in my monstrous refactor of pins right now so I'll have to get back to this later. Still, it's a step forward.

(in other words, feel free to dig into this - it won't be duplicated effort as I'm not going to get back to this today!)

Ah, I was just about to note the requirement for `mock` (under Py2.x anyway - mock got included in the stdlib sometime in 3.x but I forget where exactly). Personally,...

Yup, this was largely the point of the pins implementation - to allow IO expanders like this to be used with all the existing device classes. Basically what we'll need...