Skip to content

Replace abstractproperty with property + abstractmethod #267

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
Sep 13, 2022
Merged
Show file tree
Hide file tree
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
3 changes: 2 additions & 1 deletion importlib_resources/abc.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,8 @@ def open(self, mode='r', *args, **kwargs):
accepted by io.TextIOWrapper.
"""

@abc.abstractproperty
@property
@abc.abstractmethod
def name(self) -> str:
"""
The base name of this object without any parent references.
Expand Down
3 changes: 2 additions & 1 deletion importlib_resources/simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ class SimpleReader(abc.ABC):
provider.
"""

@abc.abstractproperty
@property
@abc.abstractmethod
def package(self) -> str:
"""
The name of the package for which this reader loads resources.
Expand Down