Skip to content

ENH: Improve clipboard #201

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

Merged
merged 7 commits into from
Aug 22, 2022
Merged

ENH: Improve clipboard #201

merged 7 commits into from
Aug 22, 2022

Conversation

bashtage
Copy link
Contributor

Synchronize clipboard with upstream pandas

  • Tests added: Please use assert_type() to assert the type of any return value

Synchronize clipboard with upstream pandas
@bashtage
Copy link
Contributor Author

Pretty hard to add tests for so nothing added so far.

Copy link
Collaborator

@Dr-Irv Dr-Irv left a comment

Choose a reason for hiding this comment

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

Given that the kwargs are the same as read_csv for read_clipboard and the same as to_csv for to_clipboard, we should copy those arguments over to here, and remove the kwargs

For testing, you could do a to_clipboard followed by read_clipboard

@bashtage
Copy link
Contributor Author

bashtage commented Aug 18, 2022

Clipboard testing doesn't work on linux CI without extra setup. Maintaining the CI setup is not worth it IMO. I will skip the test if the to_clipboard fails.

@bashtage
Copy link
Contributor Author

Test added. It runs on windows but not linux.

@Dr-Irv
Copy link
Collaborator

Dr-Irv commented Aug 22, 2022

Given that the kwargs are the same as read_csv for read_clipboard and the same as to_csv for to_clipboard, we should copy those arguments over to here, and remove the kwargs

@bashtage Do you think you could do this as well? No need to add a test for all the args, but you could copy them over.

Expand kwargs
Add types for all read_csv args
@bashtage
Copy link
Contributor Author

I've added the kwargs from read_csv - Warning: There are a lot. Turns out clipboard can also return a TextFileReader too.

Copy link
Collaborator

@Dr-Irv Dr-Irv left a comment

Choose a reason for hiding this comment

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

thanks @bashtage

@Dr-Irv Dr-Irv merged commit 1aa40eb into pandas-dev:main Aug 22, 2022
@bashtage bashtage deleted the io-clipboard branch August 23, 2022 09:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants