diff --git a/doc/install.rst b/doc/install.rst index e4ecd643..26041424 100644 --- a/doc/install.rst +++ b/doc/install.rst @@ -134,9 +134,3 @@ numpydoc_validation_exclude : set validation. Only has an effect when docstring validation is activated, i.e. ``numpydoc_validation_checks`` is not an empty set. -numpydoc_edit_link : bool - .. deprecated:: 0.7.0 - - edit your HTML template instead - - Whether to insert an edit link after docstrings. diff --git a/numpydoc/numpydoc.py b/numpydoc/numpydoc.py index 773079b9..93a1809b 100644 --- a/numpydoc/numpydoc.py +++ b/numpydoc/numpydoc.py @@ -196,16 +196,6 @@ def mangle_docstrings(app, what, name, obj, options, lines): logger.warning(msg) - if (app.config.numpydoc_edit_link and hasattr(obj, '__name__') and - obj.__name__): - if hasattr(obj, '__module__'): - v = dict(full_name=f"{obj.__module__}.{obj.__name__}") - else: - v = dict(full_name=obj.__name__) - lines += ['', '.. htmlonly::', ''] - lines += [f' {x}' for x in - (app.config.numpydoc_edit_link % v).split("\n")] - # call function to replace reference numbers so that there are no # duplicates rename_references(app, what, name, obj, options, lines) @@ -266,7 +256,6 @@ def setup(app, get_doc_object_=get_doc_object): app.connect('autodoc-process-signature', mangle_signature) app.connect('doctree-read', relabel_references) app.connect('doctree-resolved', clean_backrefs) - app.add_config_value('numpydoc_edit_link', None, False) app.add_config_value('numpydoc_use_plots', None, False) app.add_config_value('numpydoc_use_blockquotes', None, False) app.add_config_value('numpydoc_show_class_members', True, True) diff --git a/numpydoc/tests/test_numpydoc.py b/numpydoc/tests/test_numpydoc.py index 26ff3d28..f319269a 100644 --- a/numpydoc/tests/test_numpydoc.py +++ b/numpydoc/tests/test_numpydoc.py @@ -21,7 +21,6 @@ class MockConfig(): numpydoc_xref_aliases_complete = deepcopy(DEFAULT_LINKS) numpydoc_xref_ignore = set() templates_path = [] - numpydoc_edit_link = False numpydoc_citation_re = '[a-z0-9_.-]+' numpydoc_attributes_as_param_list = True numpydoc_validation_checks = set()