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

feat: show native object (if possible) in repr #1702

Merged
merged 5 commits into from
Jan 2, 2025

Conversation

MarcoGorelli
Copy link
Member

What type of PR is this? (check all applicable)

  • πŸ’Ύ Refactor
  • ✨ Feature
  • πŸ› Bug Fix
  • πŸ”§ Optimization
  • πŸ“ Documentation
  • βœ… Test
  • 🐳 Other

Related issues

  • Related issue #<issue number>
  • Closes #<issue number>

Checklist

  • Code follows style guide (ruff)
  • Tests added
  • Documented the changes

If you have comments or can explain your changes, please do so below

@MarcoGorelli MarcoGorelli added the enhancement New feature or request label Jan 1, 2025
@MarcoGorelli MarcoGorelli marked this pull request as ready for review January 1, 2025 20:52
Copy link
Member

@FBruzzesi FBruzzesi left a comment

Choose a reason for hiding this comment

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

Hands down best PR to start the year with!

HighFiveViralhogGIF

Comment on lines +24 to +34
result = nw.from_native(df).lazy().__repr__()
expected = (
"β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”\n"
"|Narwhals LazyFrame|\n"
"|------------------|\n"
"| a b |\n"
"| 0 1 fdaf |\n"
"| 1 2 fda |\n"
"| 2 3 cf |\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 admit I panicked for a moment to see values in a lazyframe, but it's pandas so all good 😁

@MarcoGorelli
Copy link
Member Author

πŸ˜„ thanks for your review!

@MarcoGorelli MarcoGorelli merged commit f58fc43 into narwhals-dev:main Jan 2, 2025
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants