-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: Enforce parse_dates as bool when scalar #12915
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
Conversation
@@ -1036,7 +1036,7 @@ def test_parse_dates_string(self): | |||
20090103,c,4,5 | |||
""" | |||
rs = self.read_csv( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you move all of the parse_dates testing to a separate class (make it a base class, kind of like ParserTests
e.g. it inherits from object
and have ParserTests
inherit from it. Ideally we would group tests like this to keep them together. Can do this in another PR if you want to organize things even more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in any event move the parse_dates
tests all together at least.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved what I think are all of the pure parse_dates
test together.
4e793c1
to
24571bd
Compare
@@ -129,7 +129,7 @@ API changes | |||
|
|||
- ``Period`` and ``PeriodIndex`` now raises ``IncompatibleFrequency`` error which inherits ``ValueError`` rather than raw ``ValueError`` (:issue:`12615`) | |||
|
|||
|
|||
- ``read_csv`` will now raise a ``TypeError`` if ``parse_dates`` is neither a boolean, list, or dictionary (:issue:`5636`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what did it do before?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing consistent AFAICT.
ok, lgtm. ping when greeen. |
Closes pandas-devgh-5636. In addition, this commit also adds validation to ensure that parse_dates is one of bool, list, or dict.
24571bd
to
321ec2f
Compare
@jreback : Travis finally got the OSX build done, and everything is green! Ready to merge. |
Was added back in pandas-devgh-12915...not sure why.
Was added back in gh-12915...not sure why.
Was added back in pandas-devgh-12915...not sure why.
Title is self-explanatory. Closes #5636.