-
Notifications
You must be signed in to change notification settings - Fork 348
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'cachedproperty' decorator replace original's method docstring #109
Comments
You might look at the implementation in Django's functional tools. I
believe its cached property decorator preserves the original docstring.
…On Fri, Jan 13, 2017, 2:39 AM Kevin Deldycke ***@***.***> wrote:
I'm using cachedproperty a lot as a decorator but the latter seems to
replace the original method's docstring by its own.
See for instance that code:
https://github.com/kdeldycke/maildir-deduplicate/blob/v2.0.1/maildir_deduplicate/mail.py#L59-L68
. It is rendered by Sphinx with the decorator's docstring instead of the
one from the decorated method. See:
https://maildir-deduplicate.readthedocs.io/en/stable/maildir_deduplicate.html#maildir_deduplicate.mail.Mail.message
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#109>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/ACNmnSYwjXBmxmW01HdsmaXsjzu4hFlOks5rRzhFgaJpZM4LipDm>
.
|
I added a pull request that should fix the issue: |
My my my, thank you @kdeldycke for the report and @induane for the fix! I've merged and will release shortly. Thanks again, both of you! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm using
cachedproperty
a lot as a decorator but the latter seems to replace the original method's docstring by its own.See for instance that code: https://github.com/kdeldycke/maildir-deduplicate/blob/v2.0.1/maildir_deduplicate/mail.py#L59-L68 . It is rendered by Sphinx with the decorator's docstring instead of the one from the decorated method. See: https://maildir-deduplicate.readthedocs.io/en/stable/maildir_deduplicate.html#maildir_deduplicate.mail.Mail.message
The text was updated successfully, but these errors were encountered: