Monkey-patching a Python instance method

Dynamically adding or overwriting an instance method in Python is rarely needed, but it’s a good excuse to explore interesting aspects of the language that aren’t always well known: the descriptor protocol, types.MethodType and partial function applicatio…

Similar

Magnum Engine integrates Python and C++

During the past four months, Magnum began its adventure into the Python world. Not just with some autogenerated bindings and not just with some autogenerated Sphinx docs — that simply wouldn’t be Magnum enough. Brace yourselves, this article will show you... (more…)

Read more »