Skip to content

Commit

Permalink
Use renderer._pages_written with builder param
Browse files Browse the repository at this point in the history
  • Loading branch information
has2k1 committed Dec 11, 2023
1 parent 882fc71 commit c013d50
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions doc/_renderers/numpydoc.py
Original file line number Diff line number Diff line change
Expand Up @@ -695,9 +695,9 @@ def summarize(self, obj: dc.Object | dc.Alias) -> str:

return ""

def pages_written(self):
def _pages_written(self, builder):
"""
Render typing information and the interlinks
"""
mods = TypingModules(self.typing_module_paths, self.builder)
mods = TypingModules(self, builder)
mods.render_information_pages()
8 changes: 4 additions & 4 deletions doc/_renderers/typing_modules.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@ class TypingModule:
"""

module_path: str
renderer: Renderer
builder: Builder

def __post_init__(self):
self.renderer = self.builder.renderer
self.package = self.builder.package
self.dir = self.builder.dir

Expand Down Expand Up @@ -140,15 +140,15 @@ class TypingModules(list[TypingModule]):
A collection of TypingModules
"""

module_paths: list[str]
renderer: Renderer
builder: Builder

def __post_init__(self):
"""
Create the list from the module_paths
"""
for module_path in self.module_paths:
self.append(TypingModule(module_path, self.builder))
for module_path in self.renderer.typing_module_paths: # type: ignore
self.append(TypingModule(module_path, self.renderer, self.builder))

def render_information_pages(self):
"""
Expand Down

0 comments on commit c013d50

Please sign in to comment.