Fix ASV imports
State: closed

#22947 broke the ASV - second time in a few days that linting the benchmarks has broken something (see #22978 / #22886)

@datapythonista, could you please require that PRs try
```
cd asv_bench
asv dev
```
to see if *collection* of benchmark works? This takes about 30 seconds and then the asv run can be aborted with CTRL+C.


Labels:
name: Benchmark
description: Performance (ASV) benchmarks

Comments:
Hello @h-vetinari! Thanks for submitting the PR.

 - There are no PEP8 issues in the file [`asv_bench/benchmarks/indexing.py`](https://github.com/h-vetinari/pandas/blob/0caad801358999ae5eb539e099ede0db7adfaabc/asv_bench/benchmarks/indexing.py) !

 - There are no PEP8 issues in the file [`asv_bench/benchmarks/join_merge.py`](https://github.com/h-vetinari/pandas/blob/0caad801358999ae5eb539e099ede0db7adfaabc/asv_bench/benchmarks/join_merge.py) !

 - There are no PEP8 issues in the file [`asv_bench/benchmarks/panel_ctor.py`](https://github.com/h-vetinari/pandas/blob/0caad801358999ae5eb539e099ede0db7adfaabc/asv_bench/benchmarks/panel_ctor.py) !

 - There are no PEP8 issues in the file [`asv_bench/benchmarks/panel_methods.py`](https://github.com/h-vetinari/pandas/blob/0caad801358999ae5eb539e099ede0db7adfaabc/asv_bench/benchmarks/panel_methods.py) !


# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/23085?src=pr&el=h1) Report
> Merging [#23085](https://codecov.io/gh/pandas-dev/pandas/pull/23085?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/296c251d0e2bd112d26b980f1798db14f264b664?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/23085/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/23085?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #23085   +/-   ##
=======================================
  Coverage   92.19%   92.19%           
=======================================
  Files         169      169           
  Lines       50911    50911           
=======================================
  Hits        46939    46939           
  Misses       3972     3972
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.61% <ø> (ø)` | :arrow_up: |
| #single | `42.3% <ø> (ø)` | :arrow_up: |


------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/23085?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/23085?src=pr&el=footer). Last update [296c251...0caad80](https://codecov.io/gh/pandas-dev/pandas/pull/23085?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

Thanks! 
We should indeed be more careful about that (I think a rebase went wrong in the end of that previous pull request)
In theory the previous changes were tested. I think we need to add `asv dev` in the CI to make sure we don't break them again. I think asv creates a machine the first time it runs, not sure if that can be avoided, I'll do some research.
@datapythonista you may want to start by seeing if this script that checks for failed asv benchmarks can run on Azure. We tried running it on travis but it would timeout.

https://github.com/pandas-dev/pandas-ci/blob/master/ci/asv.sh
Thanks @mroeschke, I didn't know about that script. I see one problem is that `asv dev` exits with status `0` even if some benchmarks fail. I need to check in more detail how does the script know that the benchmarks are failing, but will research and give it a try in azure.
Yeah it's a bit fragile in that it just greps for "failed" from the `asv dev` output. There may be a better approach.
@h-vetinari @mroeschke since #22854 we do a dry-run of the benchmarks to test that nothing is broken in the CI. We do it only if something in the benchmarks directory has changed, as it takes too long to do it for every PR/commit. I'm using the same grep, couldn't find a better way.
@datapythonista Cool, thanks for that!