We've discovered a memory leak in matplotlib (which uses PyCXX), and valgrind seems to be pointing at ExtensionOldType::getattr_methods. It seems that the temporary PyCObject that points to the method (created on line 176) is never getting deref'd. Attached is a patch that seems to resolve the memory leak. Does this patch make sense, or it possible we (i.e. the matplotlib folks) are using PyCXX wrong?