Skip to content

Commit c898c6c

Browse files
Remove deprecated numpydoc_edit_link (#372)
Deprecated in 2017
1 parent 51f5353 commit c898c6c

File tree

3 files changed

+0
-18
lines changed

3 files changed

+0
-18
lines changed

doc/install.rst

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,3 @@ numpydoc_validation_exclude : set
134134
validation.
135135
Only has an effect when docstring validation is activated, i.e.
136136
``numpydoc_validation_checks`` is not an empty set.
137-
numpydoc_edit_link : bool
138-
.. deprecated:: 0.7.0
139-
140-
edit your HTML template instead
141-
142-
Whether to insert an edit link after docstrings.

numpydoc/numpydoc.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -196,16 +196,6 @@ def mangle_docstrings(app, what, name, obj, options, lines):
196196
logger.warning(msg)
197197

198198

199-
if (app.config.numpydoc_edit_link and hasattr(obj, '__name__') and
200-
obj.__name__):
201-
if hasattr(obj, '__module__'):
202-
v = dict(full_name=f"{obj.__module__}.{obj.__name__}")
203-
else:
204-
v = dict(full_name=obj.__name__)
205-
lines += ['', '.. htmlonly::', '']
206-
lines += [f' {x}' for x in
207-
(app.config.numpydoc_edit_link % v).split("\n")]
208-
209199
# call function to replace reference numbers so that there are no
210200
# duplicates
211201
rename_references(app, what, name, obj, options, lines)
@@ -266,7 +256,6 @@ def setup(app, get_doc_object_=get_doc_object):
266256
app.connect('autodoc-process-signature', mangle_signature)
267257
app.connect('doctree-read', relabel_references)
268258
app.connect('doctree-resolved', clean_backrefs)
269-
app.add_config_value('numpydoc_edit_link', None, False)
270259
app.add_config_value('numpydoc_use_plots', None, False)
271260
app.add_config_value('numpydoc_use_blockquotes', None, False)
272261
app.add_config_value('numpydoc_show_class_members', True, True)

numpydoc/tests/test_numpydoc.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ class MockConfig():
2121
numpydoc_xref_aliases_complete = deepcopy(DEFAULT_LINKS)
2222
numpydoc_xref_ignore = set()
2323
templates_path = []
24-
numpydoc_edit_link = False
2524
numpydoc_citation_re = '[a-z0-9_.-]+'
2625
numpydoc_attributes_as_param_list = True
2726
numpydoc_validation_checks = set()

0 commit comments

Comments
 (0)