Drop lots of legacy code. Support Python 3.7-3.11.
[librarian.git] / src / librarian / embeds / mathml.py
index 16fa75b..f633fc4 100644 (file)
@@ -1,8 +1,7 @@
-# -*- coding: utf-8 -*-
-from __future__ import unicode_literals
-
+# This file is part of Librarian, licensed under GNU Affero GPLv3 or later.
+# Copyright © Fundacja Wolne Lektury. See NOTICE for more information.
+#
 from lxml import etree
-import six
 from librarian import get_resource
 from . import TreeEmbed, create_embed, downgrades_to
 
@@ -24,7 +23,7 @@ class MathML(TreeEmbed):
         """
         xslt = etree.parse(get_resource('res/embeds/mathml/mathml2latex.xslt'))
         output = self.tree.xslt(xslt)
-        text = six.text_type(output)
+        text = str(output)
         # Workaround for entities being preserved in output.
         # But there should be a better way.
         text = text.replace('&lt;', '<').replace('&amp;', '&')