Skip to content

Commit

Permalink
prefix InheritDocstrings with underscore
Browse files Browse the repository at this point in the history
  • Loading branch information
braingram committed Nov 16, 2023
1 parent 7cd94f8 commit 5247a69
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion asdf/generic_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def read(self, nbytes=None):
return content


class GenericFile(metaclass=util.InheritDocstrings):
class GenericFile(metaclass=util._InheritDocstrings):
"""
Base class for an abstraction layer around a number of different
file-like types. Each of its subclasses handles a particular kind
Expand Down
6 changes: 3 additions & 3 deletions asdf/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ def minversion(module, version, inclusive=True):
return Version(module_version) > Version(version)


class InheritDocstrings(type):
class _InheritDocstrings(type):
"""
This metaclass makes methods of a class automatically have their
docstrings filled in from the methods they override in the base
Expand All @@ -405,8 +405,8 @@ class InheritDocstrings(type):
For example::
>>> from asdf.util import InheritDocstrings
>>> class A(metaclass=InheritDocstrings):
>>> from asdf.util import _InheritDocstrings
>>> class A(metaclass=_InheritDocstrings):
... def wiggle(self):
... "Wiggle the thingamajig"
... pass
Expand Down

0 comments on commit 5247a69

Please sign in to comment.