Skip to content

Commit

Permalink
Reject --tracemalloc in pyperf command (#131)
Browse files Browse the repository at this point in the history
  • Loading branch information
oraluben authored Jul 21, 2022
1 parent 6be960e commit 1fd8dae
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 0 additions & 1 deletion TODO.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ BUGS
====

* Repair PyPy on Travis
* Reject --tracemalloc in bench_command()
* BUG: "python pyperf timeit --compare-to=pypy" doesn't tune correctly the runner
for pypy. pypy requires more warmup values (10) than cpython (1).
* BUG: --duplicate of timeit must be ignored in PyPy, see the discussion
Expand Down
6 changes: 6 additions & 0 deletions doc/changelog.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
Changelog
=========

Version 2.4.1
-------------

* Reject --tracemalloc in ``pyperf command``.
Patch by Yichen Yan

Version 2.4.0 (2022-07-20)
--------------------------

Expand Down
2 changes: 2 additions & 0 deletions pyperf/_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,8 @@ def _process_args_impl(self):
self._only_in_worker("--worker-task")

if args.tracemalloc:
if args.action == 'command':
raise CLIError('--tracemalloc cannot be used with pyperf command')
try:
import tracemalloc # noqa
except ImportError as exc:
Expand Down

0 comments on commit 1fd8dae

Please sign in to comment.