Skip to content

REF: Enhance consistency on Styler methods #45780

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
Mar 18, 2022

Conversation

staticdev
Copy link
Contributor

@staticdev staticdev commented Feb 2, 2022

  • Tests added and passed if fixing a bug or adding a new feature
  • All code checks passed.
  • Added an entry in the latest doc/source/whatsnew/v1.4.1.rst file if fixing a bug or adding a new feature. NOT NEEDED

pandas 1.4.0 introduces deprecation of hide_columns() and hide_index() in favor to hide(). Problem is the messages docstrings, parameters and warning messages pass parameters in different ways making it confusing and non-readable. This PR was created to address that and make all those consistent.

@attack68
Copy link
Contributor

attack68 commented Feb 2, 2022

This effectively just changes the quotation symbol from single to double quotes in a warning. No need for a whatsnew entry.

Not really convinced that the error is unreadable with single quotes instead of double:

Screen Shot 2022-02-02 at 19 08 20

@jreback
Copy link
Contributor

jreback commented Feb 3, 2022

This effectively just changes the quotation symbol from single to double quotes in a warning. No need for a whatsnew entry.

Not really convinced that the error is unreadable with single quotes instead of double:

Screen Shot 2022-02-02 at 19 08 20

can you check this for consistency with other deprecations that include quotes. a) we are probably not consistent b) we could check forth this (maybe)

@staticdev
Copy link
Contributor Author

@attack68 @jreback I checked on whole code, warning is consistent with the quotes inside the columns, also the command is also consistent with black if people want to copy-paste the code.

@staticdev staticdev changed the title Enhance consistency on Styler hide methods REF: Enhance consistency on Styler hide methods Feb 3, 2022
@staticdev staticdev changed the title REF: Enhance consistency on Styler hide methods REF: Enhance consistency on Styler methods Feb 3, 2022
@jreback
Copy link
Contributor

jreback commented Feb 27, 2022

@staticdev status of this?

@jreback jreback added the Styler conditional formatting using DataFrame.style label Feb 28, 2022
@staticdev
Copy link
Contributor Author

@jreback from my side it is ready to be merged.

@staticdev
Copy link
Contributor Author

@attack68 fine, I commited your suggestion.

@mroeschke mroeschke added this to the 1.5 milestone Mar 18, 2022
@mroeschke mroeschke merged commit 6da08eb into pandas-dev:main Mar 18, 2022
@mroeschke
Copy link
Member

Thanks @staticdev and @attack68 for merging in main one more time.

yehoshuadimarsky pushed a commit to yehoshuadimarsky/pandas that referenced this pull request Jul 13, 2022
* Enhance consistency on Styler hide methods

* Docs and checks

* Make set_sticky consistent with all other methods

* Remove whatsnew

* Apply suggestions from code review

Co-authored-by: JHM Darbyshire <[email protected]>

Co-authored-by: JHM Darbyshire <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Styler conditional formatting using DataFrame.style
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants