File: pyhon3.12-syntax.patch

package info (click to toggle)
sortmerna 4.3.7-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 134,048 kB
  • sloc: cpp: 24,424; ansic: 15,923; python: 1,453; sh: 224; makefile: 31
file content (20 lines) | stat: -rw-r--r-- 1,110 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Description: Fix Python3.12 string syntax
Bug-Debian: https://bugs.debian.org/1087092
Author: Andreas Tille <tille@debian.org>
Last-Update: 2024-06-11
Forwarded: https://github.com/sortmerna/sortmerna/issues/434

--- a/scripts/run.py
+++ b/scripts/run.py
@@ -255,9 +255,9 @@ def parse_log(fpath, logd={}):
             elif logd['results']['num_denovo'][0] in line:
                 logd['results']['num_denovo'][1] = int((re.split(' = ', line)[1]).strip())
             elif logd['results']['num_hits'][0] in line:
-                logd['results']['num_hits'][1] = int((re.split(' = | \(', line)[1]).strip())
+                logd['results']['num_hits'][1] = int((re.split(r' = | \(', line)[1]).strip())
             elif logd['results']['num_fail'][0] in line:
-                logd['results']['num_fail'][1] = int((re.split(' = | \(', line)[1]).strip())
+                logd['results']['num_fail'][1] = int((re.split(r' = | \(', line)[1]).strip())
             elif logd['num_id_cov'][0] in line:
                 # line: '..thresholds = 44223 (44.22)'
                 val = line.split('=')[1]