File: fix-python3.14-annotations.patch

package info (click to toggle)
propka 3.5.1-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,920 kB
  • sloc: python: 7,156; makefile: 39
file content (15 lines) | stat: -rw-r--r-- 659 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Description: Fix FTBFS due to the change in annotation handling in Python 3.14.
Author: Matthew Burn
Forwarded: https://github.com/jensengroup/propka/pull/199
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1123164
--- a/propka/parameters.py
+++ b/propka/parameters.py
@@ -145,7 +145,7 @@
         if len(words) == 0:
             return
         # parse the words
-        typeannotation = self.__annotations__.get(words[0])
+        typeannotation = type(self).__annotations__.get(words[0])
         if typeannotation is _T_NUMBER_DICTIONARY:
             self.parse_to_number_dictionary(words)
         elif typeannotation is _T_STRING_LIST: