You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# code.pydeffoo(bar: int, baz: str="qux") ->None:
"""This is a docstring"""passclassFoo:
"""This is a class docstring"""defbar(self, bar: int, baz: str="qux") ->None:
"""This is a method docstring"""pass
fromthoth_docimportget_docstringdocstring=get_docstring("code.py", "foo") # find docstring of foo in code.pyprint(docstring) # "This is a docstring"docstring=get_docstring("code.py", "Foo") # find docstring of Foo class in code.pydocstring=get_docstring("code.py", "Foo.bar") # find docstring of Foo.bar method in code.py