Passed
Pull Request — main (#155)
by Oliver
01:50
created

silence   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 3
eloc 10
dl 0
loc 14
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A PatchedPythonDomain.resolve_xref() 0 5 2

1 Function

Rating   Name   Duplication   Size   Complexity  
A setup() 0 2 1
1
from sphinx.domains.python import PythonDomain
2
3
4
class PatchedPythonDomain(PythonDomain):
5
    def resolve_xref(self, env, fromdocname, builder, typ, target, node, contnode):
6
        if 'refspecific' in node:
7
            del node['refspecific']
8
        return super(PatchedPythonDomain, self).resolve_xref(
9
            env, fromdocname, builder, typ, target, node, contnode)
10
11
12
def setup(sphinx):
13
    sphinx.add_domain(PatchedPythonDomain, override=True)
14