summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorFrantisek Sumsal <frantisek@sumsal.cz>2023-07-17 22:51:19 +0200
committerFrantisek Sumsal <frantisek@sumsal.cz>2023-08-10 18:13:29 +0200
commit54a9070ce5af37fb8915cd4d5091357771fc9bad (patch)
tree496473c7d7c474c7550b18742b18586acc14b525 /tools
parenttools: pylint update-man-rules.py (diff)
downloadsystemd-54a9070ce5af37fb8915cd4d5091357771fc9bad.tar.xz
systemd-54a9070ce5af37fb8915cd4d5091357771fc9bad.zip
tools: pylint xml_helper.py
Diffstat (limited to 'tools')
-rwxr-xr-xtools/xml_helper.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/xml_helper.py b/tools/xml_helper.py
index bc14298653..6f71350f5b 100755
--- a/tools/xml_helper.py
+++ b/tools/xml_helper.py
@@ -3,14 +3,18 @@
from lxml import etree as tree
+
class CustomResolver(tree.Resolver):
- def resolve(self, url, id, context):
+ def resolve(self, url, _id, context):
if 'custom-entities.ent' in url:
return self.resolve_filename('man/custom-entities.ent', context)
if 'ethtool-link-mode' in url:
return self.resolve_filename('src/shared/ethtool-link-mode.xml', context)
+ return None
+
_parser = tree.XMLParser()
+# pylint: disable=no-member
_parser.resolvers.add(CustomResolver())
def xml_parse(page):