Skip to content

Commit 3618abb

Browse files
Apply suggestions from code review
Co-authored-by: ivonastojanovic <80911834+ivonastojanovic@users.noreply.github.com>
1 parent b16b0c4 commit 3618abb

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

Doc/library/profiling.sampling.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1344,7 +1344,7 @@ Sampling options
13441344

13451345
.. option:: --blocking
13461346

1347-
Stop the target process during each sample. This ensures consistent
1347+
Pause the target process during each sample. This ensures consistent
13481348
stack traces at the cost of slowing down the target. Use with longer
13491349
intervals (1000 µs or higher) to minimize impact. See :ref:`blocking-mode`
13501350
for details.

Lib/profiling/sampling/sample.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,10 @@ def sample(self, collector, duration_sec=10, *, async_aware=False):
105105
except ProcessLookupError as e:
106106
duration_sec = current_time - start_time
107107
break
108-
except (RuntimeError, UnicodeDecodeError, MemoryError, OSError) as e:
108+
except (RuntimeError, UnicodeDecodeError, MemoryError, OSError):
109109
collector.collect_failed_sample()
110110
errors += 1
111111
except Exception as e:
112-
print(e)
113112
if not _is_process_running(self.pid):
114113
break
115114
raise e from None

0 commit comments

Comments
 (0)