BUG: to_timedelta still raises with errors='ignore' · Issue #13613 · pandas-dev/pandas (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

@jorisvandenbossche

Description

@jorisvandenbossche

From the added docs in #13425:

In [10]: pd.to_timedelta(['apple', '1 day'], errors='ignore')
...
ValueError: unit abbreviation w/o a number

In [12]: pd.to_timedelta(['apple', pd.Timedelta('1day')], errors='ignore')
...
ValueError: unit abbreviation w/o a number

It's the same error as you get with errors='raise' (so not captured somewhere), errors='coerce is working correctly.