-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
[EPIC] Automatically generate all function documentation from code #12740
Comments
Update is I have a few follow on PRs
Then I figure I will file one or two other tickets to see how easy it is to port other functions And if all goes well I'll make a ticket storm to port the docs |
FYI I've finished up the string expression migration locally - just waiting on the updated code from #12742 to land before pushing a PR. |
Thanks, I'll merge those as soon as they get a review (I can't merge them until they get an approval from another committer) |
No rush I just wanted to make sure no one was duplicating work needlessly |
@alamb I think it should be mentioned here that ./dev/update_function_docs.sh should be ran, as it wasn't immediately obvious, and when I did my first migration I took a bit of time to find it. |
Thank you @jonathanc-n -- I added it to the description of #12859 and will add it on subsequent tickets |
Thanks to @jonathanc-n @Omega359 and others we are cranking right along with this. I expect it to be done sometime later this week |
I think we are pretty close here After we merge these PRs from @jonathanc-n and myself We then have: Then we have just a few more functions to document ( (venv) andrewlamb@Andrews-MacBook-Pro-2:~/Software/datafusion$ ./dev/update_function_docs.sh
/Users/andrewlamb/Software/datafusion
Inserting header
Running CLI and inserting aggregate function docs table
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.34s
Running `target/debug/print_functions_docs aggregate`
Running prettier
docs/source/user-guide/sql/aggregate_functions_new.md 59ms
'docs/source/user-guide/sql/aggregate_functions_new.md' successfully updated!
Inserting header
Running CLI and inserting scalar function docs table
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.09s
Running `target/debug/print_functions_docs scalar`
INFO: The following functions do not have documentation:
- map_values
- map_keys
- map
- map_extract
Running prettier
docs/source/user-guide/sql/scalar_functions_new.md 208ms
'docs/source/user-guide/sql/scalar_functions_new.md' successfully updated!
Inserting header
Running CLI and inserting window function docs table
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.09s
Running `target/debug/print_functions_docs window`
INFO: The following functions do not have documentation:
- lag
- lead
Running prettier
docs/source/user-guide/sql/window_functions_new.md 26ms
'docs/source/user-guide/sql/window_functions_new.md' successfully updated! |
Here is a PR to make sure no new functions are added without documentation: #12938 |
🎉 I think all we need is #13171 and we can claim this project is complete. Thanks again @Omega359 @buraksenn and @jonathanc-n for pushing it along |
🎉 epic |
Is your feature request related to a problem or challenge?
Currently, when we add a new function to DataFusion library we have to remember to document that function in the documentation, but currently we have to remember this during code review.
This has a few downsides:
@Omega359 has created the basic framework for automatically generating content in #12668
This ticket tracks the work required to port the rest of the documentation to programatic form
Tasks
alternative_syntax
function for docs #13139DESCRIBE xyz
; where xyz is a function. Ideally this would support not just the core functions in DF but also any added externally (for example those in https://github.com/datafusion-contrib/datafusion-functions-extra) and verify it works in the CLIAggregate Function Documentation Migration
Documentation
for BitwiseOperationDocumentation
for VarianceSample Port / Add Documentation forVarianceSample
andVariancePopulation
#12742Documentation
for VariancePopulation Port / Add Documentation forVarianceSample
andVariancePopulation
#12742Scalar Function Documentation Migration
Window Function Documentation Migration
Documentation
forLead
Documentation
forRowNumber
The text was updated successfully, but these errors were encountered: