chore: enforce clippy::allow_attributes for datasource crates#19068
Conversation
810241e to
9e94f57
Compare
alamb
left a comment
There was a problem hiding this comment.
looks good to me -- thank you @chakkk309
Jefffrey
left a comment
There was a problem hiding this comment.
Thanks for picking this up, left some suggestions
datafusion/doc/src/lib.rs
Outdated
| pub use udwf::window_doc_sections; | ||
|
|
||
| #[allow(rustdoc::broken_intra_doc_links)] | ||
| #[expect(rustdoc::broken_intra_doc_links)] |
There was a problem hiding this comment.
Could we also fix this instead of expecting it?
There was a problem hiding this comment.
Hi, I've identified 2 options to address the #[expect(rustdoc::broken_intra_doc_links)] in datafusion-doc/src/lib.rs. Since datafusion-doc is designed as an independent crate without dependencies on other DataFusion crates, the original intra-doc links like ScalarUDFImpl cannot be resolved.
Option 1: Simple code references
/// Documentation for use by `ScalarUDFImpl`, `AggregateUDFImpl` and `WindowUDFImpl` functions.`
Option 2: External links to docs.rs
/// Documentation for use by [`ScalarUDFImpl`], [`AggregateUDFImpl`] and [`WindowUDFImpl`] functions.
///
/// [`ScalarUDFImpl`]: https://docs.rs/datafusion-expr/latest/datafusion_expr/trait.ScalarUDFImpl.html
/// [`AggregateUDFImpl`]: https://docs.rs/datafusion-expr/latest/datafusion_expr/trait.AggregateUDFImpl.html
/// [`WindowUDFImpl`]: https://docs.rs/datafusion-expr/latest/datafusion_expr/trait.WindowUDFImpl.html
Which kind of method would we prefer for this use case?
There was a problem hiding this comment.
I think option 1 is sufficient
Co-authored-by: Jeffrey Vo <jeffrey.vo.australia@gmail.com>
|
Thanks @chakkk309 & @alamb |
Which issue does this PR close?
Part of #18881
Rationale for this change
Implement clippy::allow_attributes lint for datasource* crates
What changes are included in this PR?
#![deny(clippy::allow_attributes)]to 6 datasource module mod.rs files#[allow(...)]to#[expect(...)]:Are these changes tested?
yes
Are there any user-facing changes?
No user-facing changes.