Skip to content

Commit f523453

Browse files
committed
Fix memory_watchdog.py usage
Remove also outdated comment.
1 parent 26ef459 commit f523453

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

Lib/test/memory_watchdog.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
"""Memory watchdog: periodically read the memory usage of the main test process
22
and print it out, until terminated."""
3-
# stdin should refer to the process' /proc/<PID>/statm: we don't pass the
4-
# process' PID to avoid a race condition in case of - unlikely - PID recycling.
5-
# If the process crashes, reading from the /proc entry will fail with ESRCH.
63

74

85
import sys
@@ -28,7 +25,7 @@ def watchdog(pid):
2825

2926
def main():
3027
if len(sys.argv) != 2:
31-
print("usage: python {sys.argv[0]) pid")
28+
print(f"usage: python {sys.argv[0]} pid")
3229
sys.exit(1)
3330
pid = int(sys.argv[1])
3431

0 commit comments

Comments
 (0)