Skip to content
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

BUG (string dtype): fix escaping of newline/tab characters in the repr #60215

Merged

Conversation

jorisvandenbossche
Copy link
Member

For strings in object dtype, we escape \n, \t, \r characters in the series/dataframe repr. Doing the same here for the string dtype.

xref #54792

@jorisvandenbossche jorisvandenbossche added Output-Formatting __repr__ of pandas objects, to_string Strings String extension data type and string data labels Nov 6, 2024
@jorisvandenbossche jorisvandenbossche added this to the 2.3 milestone Nov 6, 2024
@mroeschke mroeschke merged commit 5929ae9 into pandas-dev:main Nov 6, 2024
51 checks passed
@mroeschke
Copy link
Member

Thanks @jorisvandenbossche

meeseeksmachine pushed a commit to meeseeksmachine/pandas that referenced this pull request Nov 6, 2024
@jorisvandenbossche jorisvandenbossche deleted the string-dtype-repr-escaping branch November 6, 2024 20:22
mroeschke pushed a commit that referenced this pull request Nov 6, 2024
…of newline/tab characters in the repr) (#60220)

Backport PR #60215: BUG (string dtype): fix escaping of newline/tab characters in the repr

Co-authored-by: Joris Van den Bossche <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Output-Formatting __repr__ of pandas objects, to_string Strings String extension data type and string data
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants