CI: remove failing line
State: closed


Labels:
name: CI
description: Continuous Integration

Comments:
Hello @TomAugspurger! Thanks for submitting the PR.

 - There are no PEP8 issues in the file [`asv_bench/benchmarks/frame_methods.py`](https://github.com/TomAugspurger/pandas/blob/a0a37ccbf4302bea5c8a58901fbcbd45531a80fb/asv_bench/benchmarks/frame_methods.py) !


https://travis-ci.org/pandas-dev/pandas/jobs/463403386

maybe picking up a new moto?
https://dev.azure.com/pandas-dev/pandas/_build/results?buildId=4681
I don't know about the error in travis. We started to check the benchmarks yesterday, and they just run when there are changes to it. So, I guess they were already broken, may be for a while. Happy to ignore the errors in the benchmarks here, I can take a look tonight and fix them in a separate PR, if nobody does it before.
I'm cleaning them up now. A couple are just broken / weren't updated with removal of deprecations.

The HTML repr stuff *may* be related to how we're running stuff in azure. I think I have a workaround.
@jreback @datapythonista 
The error in https://travis-ci.org/pandas-dev/pandas/jobs/463403386 is not from the asv tests, but a new (flaky?) moto/boto error. Searching for the error leads to https://stackoverflow.com/a/52417342/2965879, which recommends `pip install google-compute-engine` as a solution.

The ASVs are only properly tested since a few CI runs (after the linebreak thing?), and I guess there are still errors hiding in the code. e.g.:
```
[  0.57%] ··· algorithms.Match.time_match_string                          failed
AttributeError: module 'pandas' has no attribute 'match'
[  9.80%] ··· frame_methods.Reindex.time_reindex_both_axes_ix 
KeyError: "None of [Int64Index([4000, 4001, 4002, 4003, 4004, 4005, 4006, 4007, 4008, 4009,\n
[ 10.37%] ··· frame_methods.Repr.time_html_repr_trunc_mi 
ValueError: I/O operation on closed file
[ 10.44%] ··· frame_methods.Repr.time_html_repr_trunc_si
ValueError: I/O operation on closed file
[ 36.58%] ··· sparse.ToCoo.time_sparse_series_to_coo
ValueError: The name None occurs multiple times, use a level number
[ 47.30%] ··· algorithms.Hashing.time_series_timedeltas  
TypeError: setup_cache() takes 0 positional arguments but 1 was given
```

@TomAugspurger: didn't see you already posted something on that while I was writing...
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=h1) Report
> Merging [#24092](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/1d3ed917638b9890e0410fa996a447c4a780429e?src=pr&el=desc) will **increase** coverage by `49.68%`.
> The diff coverage is `100%`.

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

```diff
@@             Coverage Diff             @@
##           master   #24092       +/-   ##
===========================================
+ Coverage   42.52%    92.2%   +49.68%     
===========================================
  Files         161      161               
  Lines       51697    51684       -13     
===========================================
+ Hits        21982    47657    +25675     
+ Misses      29715     4027    -25688
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.61% <100%> (?)` | |
| #single | `43% <0%> (+0.48%)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/formats/html.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL2Zvcm1hdHMvaHRtbC5weQ==) | `98.61% <100%> (+98.61%)` | :arrow_up: |
| [pandas/core/sparse/scipy\_sparse.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvc3BhcnNlL3NjaXB5X3NwYXJzZS5weQ==) | `100% <100%> (+89.7%)` | :arrow_up: |
| [pandas/core/computation/pytables.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvY29tcHV0YXRpb24vcHl0YWJsZXMucHk=) | `92.37% <0%> (+0.3%)` | :arrow_up: |
| [pandas/io/pytables.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL3B5dGFibGVzLnB5) | `92.3% <0%> (+0.92%)` | :arrow_up: |
| [pandas/util/\_test\_decorators.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3RfZGVjb3JhdG9ycy5weQ==) | `93.24% <0%> (+4.05%)` | :arrow_up: |
| [pandas/compat/\_\_init\_\_.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvbXBhdC9fX2luaXRfXy5weQ==) | `58.36% <0%> (+8.17%)` | :arrow_up: |
| [pandas/core/config\_init.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvY29uZmlnX2luaXQucHk=) | `99.24% <0%> (+9.84%)` | :arrow_up: |
| [pandas/core/reshape/util.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvcmVzaGFwZS91dGlsLnB5) | `100% <0%> (+11.53%)` | :arrow_up: |
| [pandas/compat/numpy/\_\_init\_\_.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvbXBhdC9udW1weS9fX2luaXRfXy5weQ==) | `92.85% <0%> (+14.28%)` | :arrow_up: |
| [pandas/core/computation/common.py](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvY29tcHV0YXRpb24vY29tbW9uLnB5) | `85.71% <0%> (+14.28%)` | :arrow_up: |
| ... and [120 more](https://codecov.io/gh/pandas-dev/pandas/pull/24092/diff?src=pr&el=tree-more) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24092?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/24092?src=pr&el=footer). Last update [1d3ed91...ce0e25c](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=h1) Report
> Merging [#24092](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/1d3ed917638b9890e0410fa996a447c4a780429e?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/24092/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24092   +/-   ##
=======================================
  Coverage   42.52%   42.52%           
=======================================
  Files         161      161           
  Lines       51697    51697           
=======================================
  Hits        21982    21982           
  Misses      29715    29715
```

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


------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24092?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/24092?src=pr&el=footer). Last update [1d3ed91...e79d52e](https://codecov.io/gh/pandas-dev/pandas/pull/24092?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

ASV stuff fixed in 
https://github.com/pandas-dev/pandas/pull/24092/commits/1f15d1035ae435012ff0c7bb308c900889056951

Just debugging some moto stuff in 
https://github.com/pandas-dev/pandas/pull/24092/commits/e79d52e952e06535b99db0d27b45f21f5ccc7b45. Not a permenant fix.
Not sure what's up with the SSL failures, but FWIW, `pandas/tests/io/json/test_pandas.py::TestPandasContainer::test_url` is randomly hanging / skipping / passing for me locally.
Well I'm not sure what to do here...

It's possible that the network tests are hitting some bug in pytest or something, I'm not sure. We really shouldn't be hitting the network in most unit tests.

Do we want to mock these network requests?

In a hacky version, we just mock out HTTPResponse's `.read`, since that's all we use... In a more sophisticated version we mock the actual server (which we should do at a minimum). But this will be made obsolete by https://github.com/pandas-dev/pandas/pull/21504.
Merging on green (I think everything will pass this time).
@TomAugspurger 
Unfortunately, the `travis-36` job just failed. Seems the issues with the moto-import were masking the *other* issue with the crash in pytest:
```
INTERNALERROR> KeyError: <class 'ssl.SSLSocket'>
INTERNALERROR> 
INTERNALERROR> During handling of the above exception, another exception occurred:
[...]
INTERNALERROR> execnet.gateway_base.DumpError: can't serialize <class 'ssl.SSLSocket'>
```
Such a mess :) I'm marking the network tests as `single`, under the theory that they're doing something with sockets that can't be serialized.
@TomAugspurger 

I was just gonna suggest that approach. I found another xdist issue that seems to point to exactly this:
pytest-dev/pytest-xdist#384
All green. Merging.