Skip to content

Commit 68895bb

Browse files
committed
Exclude partition_label from procinfo.label when collecting labels
1 parent 4429188 commit 68895bb

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

rc/control/manage_processes_direct.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -840,9 +840,15 @@ def get_pids_and_labels_on_host(host, procinfos):
840840
cleaned_lines = [line for line in grepped_lines if " ssh " not in line]
841841

842842
labels_of_found_processes = []
843-
843+
extra = (
844+
""
845+
if self.partition_label_format is None
846+
else (
847+
self.partition_label_format % (os.environ["DAQINTERFACE_PARTITION_NUMBER"])
848+
)
849+
)
844850
for line in cleaned_lines:
845-
res = re.search(r"application_name:\s+(\S+)", line)
851+
res = re.search(r"application_name:\s+(\S+)" + extra, line)
846852
assert res
847853
labels_of_found_processes.append(res.group(1))
848854

0 commit comments

Comments
 (0)