Message ID | 20250723145507.584335-1-ross.burton@arm.com |
---|---|
State | New |
Headers | show |
Series | [1/2] pybootchartgui: mark a regex as a raw string | expand |
diff --git a/scripts/pybootchartgui/pybootchartgui/draw.py b/scripts/pybootchartgui/pybootchartgui/draw.py index 16739a0fa19..09253ea1852 100644 --- a/scripts/pybootchartgui/pybootchartgui/draw.py +++ b/scripts/pybootchartgui/pybootchartgui/draw.py @@ -844,7 +844,7 @@ def draw_header (ctx, headers, duration): toshow = [ ('system.uname', 'uname', lambda s: s), ('system.release', 'release', lambda s: s), - ('system.cpu', 'CPU', lambda s: re.sub('model name\s*:\s*', '', s, 1)), + ('system.cpu', 'CPU', lambda s: re.sub(r'model name\s*:\s*', '', s, 1)), ('system.kernel.options', 'kernel options', lambda s: s), ]
Otherwise Python tries to unescape the \s and warns that it can't. Signed-off-by: Ross Burton <ross.burton@arm.com> --- scripts/pybootchartgui/pybootchartgui/draw.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)