New submission from Nick Coghlan: While working on #8810, I was reminded of the problem of wanting to inherit docstrings while replacing a method implementation.
The abstract base class method docstrings for tzinfo.utcoffset and tzinfo.dst are also correct for the concrete subclasses in the pure Python and the C versions. However, the docstrings currently need to be duplicated in all 3 places manually. functools.wraps already plays in this space, but arguably asserts *too much* about the relationship between components A couple of descriptors on bound and unbound methods (for __doc__ and __signature__) could have dealt with this fairly easily, but we don't have unbound methods any more :( ---------- components: Library (Lib) messages: 168618 nosy: eric.snow, ncoghlan priority: normal severity: normal status: open title: Mechanism for inheriting docstrings and signatures type: enhancement versions: Python 3.4 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue15731> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com