diff options
author | Jérome Perrin <perrinjerome@gmail.com> | 2019-11-04 16:36:00 +0900 |
---|---|---|
committer | Giampaolo Rodola <g.rodola@gmail.com> | 2019-11-04 15:36:00 +0800 |
commit | ff5a4127f48143bb5c14a5340584c0ddb3c121ef (patch) | |
tree | 3efeb490b32a4ff65678b0fca9da51968bd4cea1 | |
parent | b57a644c03bf9e1edf1ede2ea46235d5dd119b84 (diff) | |
download | psutil-ff5a4127f48143bb5c14a5340584c0ddb3c121ef.tar.gz |
docs: fix TypeError in example (#1580)
Terminate my children example had some error:
log("process {} survived SIGTERM; trying SIGKILL" % p)
TypeError: not all arguments converted during string formatting
-rw-r--r-- | docs/index.rst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/index.rst b/docs/index.rst index dd83c6b9..c853abae 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -2455,7 +2455,7 @@ resources. if alive: # send SIGKILL for p in alive: - print("process {} survived SIGTERM; trying SIGKILL" % p) + print("process {} survived SIGTERM; trying SIGKILL".format(p)) try: p.kill() except psutil.NoSuchProcess: @@ -2464,7 +2464,7 @@ resources. if alive: # give up for p in alive: - print("process {} survived SIGKILL; giving up" % p) + print("process {} survived SIGKILL; giving up".format(p)) Filtering and sorting processes ------------------------------- |