You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
___________TestToDatetimeMisc.test_string_na_nat_conversion[False] ____________
[gw0] linux--Python3.7.3/home/vsts/miniconda3/envs/pandas-dev/bin/pythonself=<pandas.tests.indexes.datetimes.test_tools.TestToDatetimeMiscobjectat0x7f38c92b73c8>cache=False@pytest.mark.parametrize('cache', [True, False])deftest_string_na_nat_conversion(self, cache):
# GH #999, #858strings=np.array(['1/1/2000', '1/2/2000', np.nan,
'1/4/2000, 12:34:56'], dtype=object)
expected=np.empty(4, dtype='M8[ns]')
fori, valinenumerate(strings):
ifisna(val):
expected[i] =iNaTelse:
expected[i] =parse(val)
result=tslib.array_to_datetime(strings)[0]
tm.assert_almost_equal(result, expected)
result2=to_datetime(strings, cache=cache)
assertisinstance(result2, DatetimeIndex)
tm.assert_numpy_array_equal(result, result2.values)
malformed=np.array(['1/100/2000', np.nan], dtype=object)
# GH 10636, default is now 'raise'msg= (r"\(u?'Unknown string format:', '1/100/2000'\)|""day is out of range for month")
withpytest.raises(ValueError, match=msg):
>to_datetime(malformed, errors='raise', cache=cache)
EAssertionError: Pattern'\(u?'Unknownstringformat:', '1/100/2000'\)|day is out of range for month'notfoundin'Unknown string format: 1/100/2000'
Not sure what the root cause is. I figured should be good enough to relax the error message for the time being and not block CI for others.
@simonjayhawkins looks like you might have changed this test to add a more restrictive message so if you want to dive into further detail for a more comprehensive fix would certainly be welcome
The text was updated successfully, but these errors were encountered:
These just started showing up in the build today:
Not sure what the root cause is. I figured should be good enough to relax the error message for the time being and not block CI for others.
@simonjayhawkins looks like you might have changed this test to add a more restrictive message so if you want to dive into further detail for a more comprehensive fix would certainly be welcome
The text was updated successfully, but these errors were encountered: