mirror of
https://github.com/hwchase17/langchain.git
synced 2025-08-03 10:12:33 +00:00
docs: enable private docstring submembers sphinx (#28589)
This commit is contained in:
parent
791d7e965e
commit
1cedf401a7
@ -87,6 +87,14 @@ class Beta(BaseAdmonition):
|
|||||||
def setup(app):
|
def setup(app):
|
||||||
app.add_directive("example_links", ExampleLinksDirective)
|
app.add_directive("example_links", ExampleLinksDirective)
|
||||||
app.add_directive("beta", Beta)
|
app.add_directive("beta", Beta)
|
||||||
|
app.connect('autodoc-skip-member', skip_private_members)
|
||||||
|
|
||||||
|
def skip_private_members(app, what, name, obj, skip, options):
|
||||||
|
if skip:
|
||||||
|
return True
|
||||||
|
if hasattr(obj, '__doc__') and obj.__doc__ and ':private:' in obj.__doc__:
|
||||||
|
return True
|
||||||
|
return None
|
||||||
|
|
||||||
|
|
||||||
# -- Project information -----------------------------------------------------
|
# -- Project information -----------------------------------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user