| 1 |
Descriptionscip-debian debian cpuset 1.6.2-3 cpuset/patches/`01_SyntaxWarning.patch`#Description.: Use raw strings for regular expressions with backslashes |
| 2 |
Prefix the CPU and memory specification regular expressions with r so Python |
| 3 |
no longer emits SyntaxWarning for invalid string escape sequences. |
| 4 |
Authorscip-debian debian cpuset 1.6.2-3 cpuset/patches/`01_SyntaxWarning.patch`#Author.: Alexandre Detiste <[email protected]scip-debian . . . identity/`[email protected]`.> |
| 5 |
Forwardedscip-debian debian cpuset 1.6.2-3 cpuset/patches/`01_SyntaxWarning.patch`#Forwarded.: not-needed |
| 6 |
Bug-Debianscip-debian debian cpuset 1.6.2-3 cpuset/patches/`01_SyntaxWarning.patch`#Bug-Debian.: https://bugs.debian.org/1085531scip-debian-bts debian-bts . . 1085531: |
| 7 |
Last-Updatescip-debian debian cpuset 1.6.2-3 cpuset/patches/`01_SyntaxWarning.patch`#Last-Update.: 2025-03-15 |
| 8 |
--- a/cpuset/cset.pyscip-debian debian cpuset 1.6.2-3 cpuset/upstream/`cpuset/cset.py`: |
| 9 |
+++ b/cpuset/cset.pyscip-debian debian cpuset 1.6.2-3 cpuset/upstream/`cpuset/cset.py`: |
| 10 |
@@ -343,7 +343,7 @@ |
| 11 |
def cpuspec_check(cpuspec, usemax=True): |
| 12 |
"""check format of cpuspec for validity""" |
| 13 |
log.debug("cpuspec_check(%s)", cpuspec) |
| 14 |
|
| 15 |
+ mo = re.search(r"[^0-9,\-]", cpuspec) |
| 16 |
if mo: |
| 17 |
str = 'CPUSPEC "%s" contains invalid charaters: %s' % (cpuspec, mo.group()) |
| 18 |
log.debug(str) |
| 19 |
@@ -395,7 +395,7 @@ |
| 20 |
# information and check the memspec that way, currently we only do |
| 21 |
# a basic check |
| 22 |
log.debug("memspec_check(%s)", memspec) |
| 23 |
|
| 24 |
+ mo = re.search(r"[^0-9,\-]", memspec) |
| 25 |
if mo: |
| 26 |
str = 'MEMSPEC "%s" contains invalid charaters: %s' % (memspec, mo.group()) |
| 27 |
log.debug(str) |