Download raw body.
devel/py-html5lib fix for Python 3.14
Fix for Python 3.14 since ast.Str is no more.
ok?
diff -x CVS -Nur py-html5lib/Makefile py-html5lib.new/Makefile
--- py-html5lib/Makefile Mon Nov 17 16:10:10 2025
+++ py-html5lib.new/Makefile Tue Apr 29 06:42:12 2025
@@ -4,7 +4,7 @@
DISTNAME= html5lib-${MODPY_DISTV}
PKGNAME= py-${DISTNAME}
CATEGORIES= devel www textproc
-REVISION= 6
+REVISION= 5
HOMEPAGE= https://github.com/html5lib/html5lib-python/
diff -x CVS -Nur py-html5lib/patches/patch-setup_py py-html5lib.new/patches/patch-setup_py
--- py-html5lib/patches/patch-setup_py Wed Dec 31 19:00:00 1969
+++ py-html5lib.new/patches/patch-setup_py Mon Nov 17 16:08:35 2025
@@ -0,0 +1,25 @@
+Fix build on Python 3.14.
+
+See: https://github.com/html5lib/html5lib-python/issues/588
+
+Index: setup.py
+--- setup.py.orig
++++ setup.py
+@@ -89,9 +89,14 @@ with open(join(here, "html5lib", "__init__.py"), "rb")
+ for a in assignments:
+ if (len(a.targets) == 1 and
+ isinstance(a.targets[0], ast.Name) and
+- a.targets[0].id == "__version__" and
+- isinstance(a.value, ast.Str)):
+- version = a.value.s
++ a.targets[0].id == "__version__"):
++ if hasattr(ast, "Str") and isinstance(a.value, ast.Str):
++ version = a.value.s
++ elif (hasattr(ast, "Constant")
++ and isinstance(a.value, ast.Constant)
++ and isinstance(a.value.value, str)):
++ version = a.value.value
++assert version is not None
+
+ setup(name='html5lib',
+ version=version,
devel/py-html5lib fix for Python 3.14