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

docs(python): a user-guide chapter on pipes #16462

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

KDruzhkin
Copy link
Contributor

A companion PR to #16461.

@github-actions github-actions bot added documentation Improvements or additions to documentation python Related to Python Polars labels May 24, 2024
Copy link

codecov bot commented May 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.47%. Comparing base (534b655) to head (bf717e6).
Report is 10 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #16462      +/-   ##
==========================================
- Coverage   81.50%   81.47%   -0.04%     
==========================================
  Files        1415     1416       +1     
  Lines      186600   186906     +306     
  Branches     3014     3026      +12     
==========================================
+ Hits       152097   152275     +178     
- Misses      33973    34098     +125     
- Partials      530      533       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@stinodego stinodego left a comment

Choose a reason for hiding this comment

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

Thanks, but I would approach this a bit differenly. See my comment in the linked issue:

It makes sense to add a dedicated section for pipe in the docs, as it's a useful tool for doing custom things. It happens more often that I point out "you can do this with pipe" and people didn't know that method existed.

Not sure I would call it 'debugging with pipe' though. It's useful for more than just debugging.

A "Pipe" page could be added to the "Transformations" section. This could showcase common patterns for using pipe. The schema assertion could be one, but a more important pattern is when you want to "name" some custom transformations and use them in a chaining fashion. We can include examples for Expr, DataFrame, and LazyFrame.

@KDruzhkin
Copy link
Contributor Author

Thanks, but I would approach this a bit differenly. See my comment in the linked issue:

I will try to do it in a week.

@stinodego
Copy link
Member

stinodego commented May 27, 2024

The issues mentioned in the "cookbook" issue are great examples for pipe, e.g. trapezoid / hypot:
#13064

@KDruzhkin
Copy link
Contributor Author

@stinodego, in the previous comment you said,

A "Pipe" page could be added to the "Transformations" section.

I have tried to fit it there, but it doesn't belong.

Transformations: a short list of pre-defined elementary building blocks. User-defined functions with pipes: infinitely many and arbitrarily complex.

So I created a new top-level section. What do you think?

@KDruzhkin KDruzhkin changed the title docs(python): debugging with pipes docs(python): a user-guide chapter on pipes Jun 5, 2024
@KDruzhkin
Copy link
Contributor Author

@MarcoGorelli, judging by #17707, @stinodego is taking a break from work on polars. Can you have a look at this?

(Mentioning you, because you have reviewed a couple of my previous PRs with documentation improvements.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation python Related to Python Polars
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants