2

In mypkg/_core.py I have

class SomeClass:
    """Here is my class."""

    def __init__(self, x: int):
        self.x = x

In __init__.py I have

from mypkg._core import SomeClass

I figure there's a default configuration to avoid documenting everything that's imported, which is fine. In my case, _core.py is a private module, and I don't want to document it. I want that documentation to be exported to the top-level mypkg module documentation.

I want SomeClass to appear in the top-level mypkg documentation, but it does not.

Hatshepsut
  • 5,962
  • 8
  • 44
  • 80
  • Does this answer your question? [Have Sphinx recognize imported classes and functions instead of modules](https://stackoverflow.com/questions/43264090/have-sphinx-recognize-imported-classes-and-functions-instead-of-modules) – youngmit May 15 '20 at 18:41

0 Answers0