Skip to content

TST: catch performance warnings #18989

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jreback opened this issue Dec 29, 2017 · 3 comments · Fixed by #19001
Closed

TST: catch performance warnings #18989

jreback opened this issue Dec 29, 2017 · 3 comments · Fixed by #19001
Labels
Testing pandas testing functions or related to the test suite
Milestone

Comments

@jreback
Copy link
Contributor

jreback commented Dec 29, 2017

xref #18849

need to assert these PerformanceWarnings

cc @jbrockmendel

pandas/tests/indexes/datetimes/test_arithmetic.py::TestDatetimeIndexArithmetic::()::test_dti_sub_offset_array[Asia/Tokyo-box0]
  /home/travis/build/pandas-dev/pandas/pandas/core/indexes/datetimes.py:918: PerformanceWarning: Adding/subtracting array of DateOffsets to <class 'pandas.core.indexes.datetimes.DatetimeIndex'> not vectorized
    PerformanceWarning)
pandas/tests/indexes/datetimes/test_arithmetic.py::TestDatetimeIndexArithmetic::()::test_dti_sub_offset_array[Asia/Tokyo-Index]
  /home/travis/build/pandas-dev/pandas/pandas/core/indexes/datetimes.py:918: PerformanceWarning: Adding/subtracting array of DateOffsets to <class 'pandas.core.indexes.datetimes.DatetimeIndex'> not vectorized
    PerformanceWarning)
pandas/tests/indexes/datetimes/test_arithmetic.py::TestDatetimeIndexArithmetic::()::test_dti_sub_offset_array[US/Eastern-box0]
  /home/travis/build/pandas-dev/pandas/pandas/core/indexes/datetimes.py:918: PerformanceWarning: Adding/subtracting array of DateOffsets to <class 'pandas.core.indexes.datetimes.DatetimeIndex'> not vectorized
    PerformanceWarning)
pandas/tests/indexes/datetimes/test_arithmetic.py::TestDatetimeIndexArithmetic::()::test_dti_sub_offset_array[US/Eastern-Index]
  /home/travis/build/pandas-dev/pandas/pandas/core/indexes/datetimes.py:918: PerformanceWarning: Adding/subtracting array of DateOffsets to <class 'pandas.core.indexes.datetimes.DatetimeIndex'> not vectorized
    PerformanceWarning)
pandas/tests/indexes/datetimes/test_arithmetic.py::TestDatetimeIndexArithmetic::()::test_dti_sub_offset_array[dateutil/Asia/Singapore-box0]
  /home/travis/build/pandas-dev/pandas/pandas/core/indexes/datetimes.py:918: PerformanceWarning: Adding/subtracting array of DateOffsets to <class 'pandas.core.indexes.datetimes.DatetimeIndex'> not vectorized
@jreback jreback added the Testing pandas testing functions or related to the test suite label Dec 29, 2017
@jreback jreback added this to the 0.23.0 milestone Dec 29, 2017
@jreback
Copy link
Contributor Author

jreback commented Dec 29, 2017

cc @jbrockmendel if we can address this before anything else

@jbrockmendel
Copy link
Member

Sure, will pin this on to #18884 to avoid breaking the self-imposed moratorium on new PRs.

Out of curiosity, how does pytest to label test_dti_sub_offset_array[US/Eastern-Index] with Index but not test_dti_sub_offset_array[US/Eastern-box0] with array?

@jreback
Copy link
Contributor Author

jreback commented Dec 29, 2017

see how ids are computed in pytest. you can specify them (with the ids in paramertize), but usually not that useful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Testing pandas testing functions or related to the test suite
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants