Skip to content

TYP: Appender also works with properties #47768

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

Merged
merged 1 commit into from
Jul 18, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions pandas/util/_decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@
import warnings

from pandas._libs.properties import cache_readonly
from pandas._typing import F
from pandas._typing import (
F,
T,
)
from pandas.util._exceptions import find_stack_level


Expand Down Expand Up @@ -485,7 +488,7 @@ def __init__(self, addendum: str | None, join: str = "", indents: int = 0) -> No
self.addendum = addendum
self.join = join

def __call__(self, func: F) -> F:
def __call__(self, func: T) -> T:
func.__doc__ = func.__doc__ if func.__doc__ else ""
self.addendum = self.addendum if self.addendum else ""
docitems = [func.__doc__, self.addendum]
Expand Down