Antoine Pitrou <pit...@free.fr> added the comment: Thanks for noticing. The doc for ismethod() says:
“Return true if the object is a bound method written in Python.” and the docstring agrees with that: “Return true if the object is an instance method. [...]” So the change isn't properly a regression when reading the docs. On the other hand, it's true that some code may rely on the previous behaviour, and the discrepancy between getmembers() and a manual test can be confusing. By the way, Python 3 has ismethod() right: >>> class B: ... def f(self): pass ... >>> inspect.ismethod(B.f) False >>> inspect.ismethod(B().f) True ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue1785> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com