pydanny/cached-property

Can cached_property be a subclass of property?

Open

#26 opened on Oct 8, 2015

View on GitHub
 (3 comments) (1 reaction) (1 assignee)Python (79 forks)github user discovery
enhancementhelp wanted

Repository metrics

Stars
 (705 stars)
PR merge metrics
 (PR metrics pending)

Description

There are certain pieces of code in some libraries, linters and static analyzers that check things like

if isinstance(attr, property):
    do_something()

This is especially important for use in metaclasses.

Obviously this fails with cached property; would it be possible to derive it from property so isinstance/issubclass checks work as expected?

Contributor guide