pyperf 2.8.0__tar.gz → 2.8.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyperf-2.8.0/pyperf.egg-info → pyperf-2.8.1}/PKG-INFO +2 -3
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/changelog.rst +11 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/conf.py +1 -1
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/__init__.py +1 -1
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_process_time.py +1 -1
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_misc.py +1 -5
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_runner.py +14 -8
- {pyperf-2.8.0 → pyperf-2.8.1/pyperf.egg-info}/PKG-INFO +2 -3
- pyperf-2.8.1/pyperf.egg-info/requires.txt +4 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyproject.toml +1 -2
- pyperf-2.8.0/pyperf.egg-info/requires.txt +0 -7
- {pyperf-2.8.0 → pyperf-2.8.1}/COPYING +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/MANIFEST.in +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/README.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/TODO.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/Makefile +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/analyze.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/api.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/cli.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/developer_guide.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/bench_async_func.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/bench_async_func_with_loop_factory.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/bench_command.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/bench_func.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/bench_time_func.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/bench_timeit.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/export_csv.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/hist_scipy.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples/plot.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/examples.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/hist_scipy_telco.png +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/index.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/make.bat +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/outliers.json.gz +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/py2.json.gz +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/py3.json.gz +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/run_benchmark.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/runner.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/system.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/timeit_strip.json.gz +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/doc/user_guide.rst +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/__main__.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_bench.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_cli.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_collect_metadata.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_command.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_compare.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_cpu_utils.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_formatter.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_hooks.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_linux_memory.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_manager.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_metadata.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_psutil_memory.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_runner.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_system.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_timeit.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_timeit_cli.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_utils.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_win_memory.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/_worker.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/__init__.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/mult_list_bench.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/mult_list_py36.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/mult_list_py36_tags.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/mult_list_py37.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/mult_list_py37_tags.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/mult_list_py38.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/replay.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/telco.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_bench.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_cli.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_examples.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_metadata.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_perf_cli.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_system.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_timeit.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/test_utils.py +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf/tests/track_memory.json +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf.egg-info/SOURCES.txt +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf.egg-info/dependency_links.txt +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf.egg-info/entry_points.txt +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/pyperf.egg-info/top_level.txt +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/setup.cfg +0 -0
- {pyperf-2.8.0 → pyperf-2.8.1}/tox.ini +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pyperf
|
|
3
|
-
Version: 2.8.
|
|
3
|
+
Version: 2.8.1
|
|
4
4
|
Summary: Python module to run and analyze benchmarks
|
|
5
5
|
Author-email: Victor Stinner <vstinner@redhat.com>
|
|
6
6
|
Maintainer-email: Dong-hee Na <donghee.na@python.org>
|
|
@@ -13,13 +13,12 @@ Classifier: Natural Language :: English
|
|
|
13
13
|
Classifier: Operating System :: OS Independent
|
|
14
14
|
Classifier: Programming Language :: Python :: 3
|
|
15
15
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
16
|
-
Requires-Python: >=3.
|
|
16
|
+
Requires-Python: >=3.9
|
|
17
17
|
Description-Content-Type: text/x-rst
|
|
18
18
|
License-File: COPYING
|
|
19
19
|
Requires-Dist: psutil>=5.9.0
|
|
20
20
|
Provides-Extra: dev
|
|
21
21
|
Requires-Dist: tox; extra == "dev"
|
|
22
|
-
Requires-Dist: importlib-metadata; python_version < "3.8" and extra == "dev"
|
|
23
22
|
|
|
24
23
|
******
|
|
25
24
|
pyperf
|
|
@@ -1,6 +1,17 @@
|
|
|
1
1
|
Changelog
|
|
2
2
|
=========
|
|
3
3
|
|
|
4
|
+
Version 2.8.1 (2024-11-13)
|
|
5
|
+
--------------------------
|
|
6
|
+
|
|
7
|
+
* Bugfix: Hooks now work correctly in subprocess benchmarks (`bench.run_command`).
|
|
8
|
+
Patch by Michael Droettboom
|
|
9
|
+
* Python 3.8 is now unsupported.
|
|
10
|
+
Patch by Hugo van Kemenade
|
|
11
|
+
|
|
12
|
+
Version 2.8.0 (2024-09-30)
|
|
13
|
+
--------------------------
|
|
14
|
+
|
|
4
15
|
* Benchmarks now have a timeout.
|
|
5
16
|
Patch by Diego Russo.
|
|
6
17
|
* The example code in bench_time_func.py uses the more modern `time.perf_counter()`.
|
|
@@ -50,7 +50,7 @@ author = 'Victor Stinner'
|
|
|
50
50
|
# built documents.
|
|
51
51
|
#
|
|
52
52
|
# The short X.Y version.
|
|
53
|
-
version = release = '2.8.
|
|
53
|
+
version = release = '2.8.1'
|
|
54
54
|
|
|
55
55
|
# The language for content autogenerated by Sphinx. Refer to documentation
|
|
56
56
|
# for a list of supported languages.
|
|
@@ -107,7 +107,7 @@ def load_hooks(metadata):
|
|
|
107
107
|
import pyperf._hooks
|
|
108
108
|
|
|
109
109
|
hook_managers = pyperf._hooks.instantiate_selected_hooks(hook_names)
|
|
110
|
-
metadata["hooks"] = ", ".join(hook_managers.
|
|
110
|
+
metadata["hooks"] = ", ".join(hook_managers.keys())
|
|
111
111
|
else:
|
|
112
112
|
hook_managers = {}
|
|
113
113
|
|
|
@@ -67,11 +67,7 @@ class MiscTests(unittest.TestCase):
|
|
|
67
67
|
self.assertRaises(ValueError, parse_run_list, '1,')
|
|
68
68
|
|
|
69
69
|
def test_setup_version(self):
|
|
70
|
-
|
|
71
|
-
from importlib.metadata import version
|
|
72
|
-
except ModuleNotFoundError:
|
|
73
|
-
# Workaround for Python 3.7
|
|
74
|
-
from importlib_metadata import version
|
|
70
|
+
from importlib.metadata import version
|
|
75
71
|
|
|
76
72
|
self.assertEqual(pyperf.__version__, version("pyperf"))
|
|
77
73
|
|
|
@@ -97,10 +97,7 @@ class TestRunner(unittest.TestCase):
|
|
|
97
97
|
|
|
98
98
|
try:
|
|
99
99
|
s = pstats.Stats(name)
|
|
100
|
-
|
|
101
|
-
assert len(s.stats)
|
|
102
|
-
else:
|
|
103
|
-
assert len(s.get_stats_profile().func_profiles)
|
|
100
|
+
assert len(s.get_stats_profile().func_profiles)
|
|
104
101
|
finally:
|
|
105
102
|
if os.path.isfile(name):
|
|
106
103
|
os.unlink(name)
|
|
@@ -123,10 +120,7 @@ class TestRunner(unittest.TestCase):
|
|
|
123
120
|
try:
|
|
124
121
|
import pstats
|
|
125
122
|
s = pstats.Stats(name)
|
|
126
|
-
|
|
127
|
-
assert len(s.stats)
|
|
128
|
-
else:
|
|
129
|
-
assert len(s.get_stats_profile().func_profiles)
|
|
123
|
+
assert len(s.get_stats_profile().func_profiles)
|
|
130
124
|
finally:
|
|
131
125
|
if os.path.isfile(name):
|
|
132
126
|
os.unlink(name)
|
|
@@ -512,6 +506,18 @@ class TestRunner(unittest.TestCase):
|
|
|
512
506
|
self.assertEqual(bench.get_metadata()['command'],
|
|
513
507
|
' '.join(map(shell_quote, args)))
|
|
514
508
|
|
|
509
|
+
def test_hook_command(self):
|
|
510
|
+
args = [sys.executable, '-c', 'pass']
|
|
511
|
+
|
|
512
|
+
runner = self.create_runner('-l1 -w0 -n1 --worker --hook _test_hook'.split())
|
|
513
|
+
with tests.capture_stdout():
|
|
514
|
+
bench = runner.bench_command('bench', args)
|
|
515
|
+
|
|
516
|
+
self.assertEqual(bench.get_metadata()['command'],
|
|
517
|
+
' '.join(map(shell_quote, args)))
|
|
518
|
+
self.assertEqual(bench.get_metadata()["hooks"],
|
|
519
|
+
"_test_hook")
|
|
520
|
+
|
|
515
521
|
def test_single_instance(self):
|
|
516
522
|
runner1 = self.create_runner([]) # noqa
|
|
517
523
|
with self.assertRaises(RuntimeError):
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pyperf
|
|
3
|
-
Version: 2.8.
|
|
3
|
+
Version: 2.8.1
|
|
4
4
|
Summary: Python module to run and analyze benchmarks
|
|
5
5
|
Author-email: Victor Stinner <vstinner@redhat.com>
|
|
6
6
|
Maintainer-email: Dong-hee Na <donghee.na@python.org>
|
|
@@ -13,13 +13,12 @@ Classifier: Natural Language :: English
|
|
|
13
13
|
Classifier: Operating System :: OS Independent
|
|
14
14
|
Classifier: Programming Language :: Python :: 3
|
|
15
15
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
16
|
-
Requires-Python: >=3.
|
|
16
|
+
Requires-Python: >=3.9
|
|
17
17
|
Description-Content-Type: text/x-rst
|
|
18
18
|
License-File: COPYING
|
|
19
19
|
Requires-Dist: psutil>=5.9.0
|
|
20
20
|
Provides-Extra: dev
|
|
21
21
|
Requires-Dist: tox; extra == "dev"
|
|
22
|
-
Requires-Dist: importlib-metadata; python_version < "3.8" and extra == "dev"
|
|
23
22
|
|
|
24
23
|
******
|
|
25
24
|
pyperf
|
|
@@ -44,13 +44,12 @@ classifiers = [
|
|
|
44
44
|
"Programming Language :: Python :: 3",
|
|
45
45
|
"Topic :: Software Development :: Libraries :: Python Modules"
|
|
46
46
|
]
|
|
47
|
-
requires-python = ">=3.
|
|
47
|
+
requires-python = ">=3.9"
|
|
48
48
|
dependencies = ["psutil>=5.9.0"]
|
|
49
49
|
|
|
50
50
|
[project.optional-dependencies]
|
|
51
51
|
dev = [
|
|
52
52
|
'tox',
|
|
53
|
-
'importlib-metadata; python_version < "3.8"'
|
|
54
53
|
]
|
|
55
54
|
|
|
56
55
|
[project.scripts]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|