Skip to content

Commit

Permalink
docs: fix linkcode for identify methods patched in metaclass
Browse files Browse the repository at this point in the history
  • Loading branch information
kmnhan committed Dec 17, 2024
1 parent da5244a commit 40f2fbb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,10 @@ def linkcode_resolve(domain, info) -> str | None:
modname = info["module"]
fullname = info["fullname"]

# Handle dataloader metaclass substitution
if fullname.endswith(".identify") and not fullname.endswith(".LoaderBase.identify"):
fullname = fullname.replace(".identify", "._original_identify")

submod = sys.modules.get(modname)
if submod is None:
return None
Expand Down

0 comments on commit 40f2fbb

Please sign in to comment.