github-rest-api 0.10.1__tar.gz → 0.10.2__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.
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/PKG-INFO +1 -1
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/github_rest_api/actions/cargo.py +5 -5
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/pyproject.toml +1 -1
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/README.md +0 -0
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/github_rest_api/__init__.py +0 -0
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/github_rest_api/actions/__init__.py +0 -0
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/github_rest_api/actions/utils.py +0 -0
- {github_rest_api-0.10.1 → github_rest_api-0.10.2}/github_rest_api/github.py +0 -0
|
@@ -12,11 +12,11 @@ def _gen_temp_branch() -> str:
|
|
|
12
12
|
return "_branch_" + "".join(str(num) for num in nums)
|
|
13
13
|
|
|
14
14
|
|
|
15
|
-
def _copy_last_dev_bench() -> None:
|
|
15
|
+
def _copy_last_dev_bench(bench_dir: Path) -> None:
|
|
16
16
|
branch = _gen_temp_branch()
|
|
17
17
|
create_branch(branch)
|
|
18
18
|
switch_branch(branch="gh-pages", fetch=True)
|
|
19
|
-
src =
|
|
19
|
+
src = bench_dir / "dev/criterion"
|
|
20
20
|
if src.is_dir():
|
|
21
21
|
target = Path("target/criterion")
|
|
22
22
|
target.mkdir(parents=True, exist_ok=True)
|
|
@@ -24,12 +24,12 @@ def _copy_last_dev_bench() -> None:
|
|
|
24
24
|
switch_branch(branch=branch, fetch=False)
|
|
25
25
|
|
|
26
26
|
|
|
27
|
-
def _cargo_criterion() -> None:
|
|
27
|
+
def _cargo_criterion(bench_dir: Path) -> None:
|
|
28
28
|
"""Run `cargo criterion` to benchmark the specified branch.
|
|
29
29
|
|
|
30
30
|
:param branch: The branch to benchmark.
|
|
31
31
|
"""
|
|
32
|
-
_copy_last_dev_bench()
|
|
32
|
+
_copy_last_dev_bench(bench_dir=bench_dir)
|
|
33
33
|
cmd = "cargo criterion --message-format=json"
|
|
34
34
|
sp.run(cmd, shell=True, check=True)
|
|
35
35
|
|
|
@@ -203,7 +203,7 @@ def benchmark(
|
|
|
203
203
|
user_email=f"bench-bot@{repo}.com",
|
|
204
204
|
user_name="bench-bot",
|
|
205
205
|
)
|
|
206
|
-
_cargo_criterion()
|
|
206
|
+
_cargo_criterion(bench_dir=bench_dir)
|
|
207
207
|
_copy_bench_results(bench_dir=bench_dir, storage=storage)
|
|
208
208
|
dirs = _clean_bench_dirs(bench_dir=bench_dir, history=history)
|
|
209
209
|
_rename_bench_reports(dirs)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|