From d7d4b7c39cb7e854cf9cc692e9a6fb7bafd7ec58 Mon Sep 17 00:00:00 2001 From: Marc Garcia Date: Mon, 4 Apr 2022 14:28:01 +0100 Subject: [PATCH 1/3] CI: Remove grep from asv call (using strict parameter instead) --- .github/workflows/code-checks.yml | 6 +----- asv_bench/benchmarks/fail.py | 3 +++ 2 files changed, 4 insertions(+), 5 deletions(-) create mode 100644 asv_bench/benchmarks/fail.py diff --git a/.github/workflows/code-checks.yml b/.github/workflows/code-checks.yml index aac6f4387a74a..f38adfddc0fe7 100644 --- a/.github/workflows/code-checks.yml +++ b/.github/workflows/code-checks.yml @@ -141,11 +141,7 @@ jobs: run: | cd asv_bench asv machine --yes - # TODO add `--durations` when we start using asv >= 0.5 (#46598) - asv run --quick --dry-run --python=same | sed "/failed$/ s/^/##[error]/" | tee benchmarks.log - if grep "failed" benchmarks.log > /dev/null ; then - exit 1 - fi + asv run --quick --dry-run --strict --durations --python=same build_docker_dev_environment: name: Build Docker Dev Environment diff --git a/asv_bench/benchmarks/fail.py b/asv_bench/benchmarks/fail.py new file mode 100644 index 0000000000000..1fd78468e80b6 --- /dev/null +++ b/asv_bench/benchmarks/fail.py @@ -0,0 +1,3 @@ +class FailBenchmarks: + def time_cause_asv_to_exit_with_non_zero_code(self): + raise ValueError('If the CI build is red, things work as expected') From 88aab448674d114e2fe2144917a593362cebc2b9 Mon Sep 17 00:00:00 2001 From: Marc Garcia Date: Mon, 4 Apr 2022 15:54:10 +0100 Subject: [PATCH 2/3] Removing debug failure --- asv_bench/benchmarks/fail.py | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 asv_bench/benchmarks/fail.py diff --git a/asv_bench/benchmarks/fail.py b/asv_bench/benchmarks/fail.py deleted file mode 100644 index 1fd78468e80b6..0000000000000 --- a/asv_bench/benchmarks/fail.py +++ /dev/null @@ -1,3 +0,0 @@ -class FailBenchmarks: - def time_cause_asv_to_exit_with_non_zero_code(self): - raise ValueError('If the CI build is red, things work as expected') From 7bbed41275db0e91118c3e76eed6ca9c4ba86a10 Mon Sep 17 00:00:00 2001 From: Marc Garcia Date: Mon, 4 Apr 2022 17:25:06 +0100 Subject: [PATCH 3/3] Show only top 30 durations --- .github/workflows/code-checks.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/code-checks.yml b/.github/workflows/code-checks.yml index f38adfddc0fe7..a5fd72e343c16 100644 --- a/.github/workflows/code-checks.yml +++ b/.github/workflows/code-checks.yml @@ -141,7 +141,7 @@ jobs: run: | cd asv_bench asv machine --yes - asv run --quick --dry-run --strict --durations --python=same + asv run --quick --dry-run --strict --durations=30 --python=same build_docker_dev_environment: name: Build Docker Dev Environment