]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-5978: Document that profiling needs cmd/function to return (GH-7938)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sat, 28 Jul 2018 12:23:42 +0000 (05:23 -0700)
committerGitHub <noreply@github.com>
Sat, 28 Jul 2018 12:23:42 +0000 (05:23 -0700)
<!-- issue-number: bpo-5978 -->
https://bugs.python.org/issue5978
<!-- /issue-number -->
(cherry picked from commit 937fb55d35373fd2701078251840b6be0465a6e1)

Co-authored-by: Andrés Delfino <adelfino@gmail.com>
Doc/library/profile.rst

index 3f3c8a9485627387f45d01e97879b2003a7406d2..926d7757e8eb34113a181c6c4d777e4b68710029 100644 (file)
@@ -297,6 +297,11 @@ functions:
 
       Profile ``func(*args, **kwargs)``
 
+Note that profiling will only work if the called command/function actually
+returns.  If the interpreter is terminated (e.g. via a :func:`sys.exit` call
+during the called command/function execution) no profiling results will be
+printed.
+
 .. _profile-stats:
 
 The :class:`Stats` Class