From 15cafc542c588d57ec10e8770bce10fb21c5594c Mon Sep 17 00:00:00 2001 From: Yoon Kyong Sik Date: Tue, 11 Mar 2025 17:13:21 +0900 Subject: [PATCH] Update bpytop.py - Fix DeprecatedWarning /home/linuxbrew/.linuxbrew/bin/bpytop:5133: DeprecationWarning: 'count' is passed as positional argument name = re.sub( ".*" + rem_line + ".*:", "", line,1).lstrip() --- bpytop.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bpytop.py b/bpytop.py index eff3704..e54d06a 100755 --- a/bpytop.py +++ b/bpytop.py @@ -5130,7 +5130,7 @@ def get_cpu_name() -> str: if rem_line: for line in cmd_out.split("\n"): if rem_line in line: - name = re.sub( ".*" + rem_line + ".*:", "", line,1).lstrip() + name = re.sub( ".*" + rem_line + ".*:", "", line, count=1).lstrip() else: name = cmd_out nlist = name.split(" ")