File: 0001-Python-3.14-support.patch

package info (click to toggle)
python-html5rdf 1.2.1-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,468 kB
  • sloc: python: 12,794; makefile: 3
file content (29 lines) | stat: -rw-r--r-- 942 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
From: Stefano Rivera <stefano@rivera.za.net>
Date: Sat, 3 Jan 2026 19:59:59 -0400
Subject: Python 3.14 support

The AST Constant `.s` attribute was replaced by `.value`

See: https://github.com/python/cpython/issues/119562

Forwarded: https://github.com/RDFLib/html5rdf/pull/5
Bug-Debian: https://bugs.debian.org/1122464
---
 setup.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/setup.py b/setup.py
index 70e2e6b..e148f75 100644
--- a/setup.py
+++ b/setup.py
@@ -87,8 +87,8 @@ with open(join(here, "html5rdf", "__init__.py"), "rb") as init_file:
         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
+                isinstance(a.value, ast.Constant)):
+            version = a.value.value
 
 setup(name='html5rdf',
       version=version,