Skip to content

BUG: parase_dates column is in dataframe (#31251) #31550

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
wants to merge 111 commits into from

Conversation

sathyz
Copy link
Contributor

@sathyz sathyz commented Feb 1, 2020


def test_missing_column(all_parsers):
parser = all_parsers
content = StringIO("time,val\n" "212.23, 32\n")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe that the CI will fail because, this string is not concatenated, can ou please concatenate them?



def test_missing_column(all_parsers):
parser = all_parsers
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add the github issue number as a comment here?

@jschendel jschendel added the Testing pandas testing functions or related to the test suite label Feb 1, 2020
@jschendel jschendel added this to the 1.1 milestone Feb 1, 2020
Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a what’s new message for v1.1?

@@ -3278,6 +3278,8 @@ def _isindex(colspec):
if is_scalar(colspec):
if isinstance(colspec, int) and colspec not in data_dict:
colspec = orig_names[colspec]
elif colspec not in orig_names:
raise ValueError(f"'{colspec}' is not in list")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
raise ValueError(f"'{colspec}' is not in list")
raise ValueError(f"Missing column provided to ‘parse_dates’: '{colspec}'")

Not tied to the wording but I don’t think “is not in list” is super clear to the end user, so could improve a bit

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had missed to check CParser, handled it now.

jbrockmendel and others added 19 commits February 1, 2020 18:23
…ers (pandas-dev#31380)

* BUG: Timedelta components no longer rounded with high precision integers

* Simplify NaT.total_seconds

* Also simplify another tz conversion code path
simonjayhawkins and others added 24 commits February 6, 2020 09:37
Remove unrequired channel
@gfyoung wrote this function here
pandas-dev#30999 (comment)
so we can ignore error messages without breaking fututre CI tests of
bare pytest raises calls

Co-authored-by: gfyoung <[email protected]>

xref pandas-devgh-30999
* REF: Move Loc-only methods to Loc

* rebase fixup

* merge fixup
@sathyz
Copy link
Contributor Author

sathyz commented Feb 8, 2020

I had made a mistake on trying to resolve conflict. will have to open a new PR.

@sathyz sathyz closed this Feb 8, 2020
@ShaharNaveh
Copy link
Member

My way around this kind of thing is:

git fetch upstream
git rebase upstream/master

But it's not a good practice because you'll need to force-push it

git push origin branch-name --force

@sathyz
Copy link
Contributor Author

sathyz commented Feb 28, 2020

@MomIsBestFriend I think I messed up again and got the same problem in #31815.

@ShaharNaveh
Copy link
Member

@sathyz I reccomend you to read this, which is a blog written by @datapythonista

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 this pull request may close these issues.

read_csv: if parse_dates dont appear in use_cols, we get a trace