Repository navigation
Clippy failing on main branch #3136
Copy link
Copy link
Closed
Description
Conflicting PRs were merged in. Following the merge, they introduced changes which fail clippy. The code itself compiles fine.
This issue tracks addressing the Clippy findings.
❯ make check-clippy
cargo clippy --all-targets --all-features --workspace -- -D warnings
Checking datafusion-functions-table v54.1.0
Checking datafusion-catalog-listing v54.1.0
Checking iceberg v0.10.1 (/Users/djonesoa/devel/iceberg-rust/crates/iceberg)
error: use of deprecated method `scan::task::FileScanTaskDeleteFileBuilder::<((std::string::String,), (u64,), (spec::manifest::data_file::DataContentType,), (), __partition_spec_id, __equality_ids, __referenced_data_file, __content_offset, __content_size_in_bytes, __record_count, __key_metadata)>::build`: Missing required field file_format
--> crates/iceberg/src/arrow/reader/pipeline.rs:2416:14
|
2416 | .build();
| ^^^^^
|
= note: `-D deprecated` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(deprecated)]`
error[E0061]: this method takes 1 argument but 0 arguments were supplied
--> crates/iceberg/src/arrow/reader/pipeline.rs:2416:14
|
2416 | .build();
| ^^^^^-- argument #1 of type `scan::task::FileScanTaskDeleteFileBuilder_Error_Missing_required_field_file_format` is missing
|
note: method defined here
--> crates/iceberg/src/scan/task.rs:340:59
|
340 | #[derive(Debug, Clone, Serialize, Deserialize, PartialEq, TypedBuilder)]
| ^^^^^^^^^^^^
= note: this error originates in the derive macro `TypedBuilder` (in Nightly builds, run with -Z macro-backtrace for more info)
help: provide the argument
|
2416 | .build(/* scan::task::FileScanTaskDeleteFileBuilder_Error_Missing_required_field_file_format */);
| ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
error: unreachable statement
--> crates/iceberg/src/arrow/reader/pipeline.rs:2417:9
|
2411 | let delete = FileScanTaskDeleteFile::builder()
| ______________________-
2412 | | .with_file_path(del_path.clone())
2413 | | .with_file_size_in_bytes(std::fs::metadata(&del_path).unwrap().len())
2414 | | .with_file_type(DataContentType::PositionDeletes)
2415 | | .with_partition_spec_id(0)
2416 | | .build();
| |____________________- any code following this expression is unreachable
2417 | let task = row_id_task_with_options(data_path, Some(100), 0, 0, vec![delete]);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unreachable statement
|
= note: `-D unreachable-code` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(unreachable_code)]`
error[E0271]: type mismatch resolving `<Iter<IntoIter<...>> as Stream>::Item == Result<FileScanTask, ...>`
--> crates/iceberg/src/arrow/reader/positional_deletes.rs:1013:21
|
1013 | let tasks = Box::pin(futures::stream::iter(vec![Ok(task)])) as FileScanTaskStream;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Result<FileScanTask, Error>`, found `Result<Result<FileScanTask, Error>, _>`
|
= note: expected enum `std::result::Result<scan::task::FileScanTask, error::Error>`
found enum `std::result::Result<std::result::Result<scan::task::FileScanTask, error::Error>, _>`
= note: required for the cast from `Pin<Box<Iter<IntoIter<Result<Result<FileScanTask, Error>, _>>>>>` to `Pin<Box<dyn Stream<Item = Result<FileScanTask, Error>> + Send>>`
= note: the full name for the type has been written to '/Users/djonesoa/devel/iceberg-rust/target/debug/deps/iceberg-5aac7f4d74e1c8e0.long-type-15410309127640329823.txt'
= note: consider using `--verbose` to print the full type name to the console
error[E0271]: type mismatch resolving `<Iter<IntoIter<...>> as Stream>::Item == Result<FileScanTask, ...>`
--> crates/iceberg/src/arrow/reader/positional_deletes.rs:1110:21
|
1110 | let tasks = Box::pin(futures::stream::iter(vec![Ok(task)])) as FileScanTaskStream;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Result<FileScanTask, Error>`, found `Result<Result<FileScanTask, Error>, _>`
|
= note: expected enum `std::result::Result<scan::task::FileScanTask, error::Error>`
found enum `std::result::Result<std::result::Result<scan::task::FileScanTask, error::Error>, _>`
= note: required for the cast from `Pin<Box<Iter<IntoIter<Result<Result<FileScanTask, Error>, _>>>>>` to `Pin<Box<dyn Stream<Item = Result<FileScanTask, Error>> + Send>>`
= note: the full name for the type has been written to '/Users/djonesoa/devel/iceberg-rust/target/debug/deps/iceberg-5aac7f4d74e1c8e0.long-type-5524797487524419931.txt'
= note: consider using `--verbose` to print the full type name to the console
Checking datafusion v54.1.0
Checking datafusion-proto v54.1.0
Checking datafusion-ffi v54.1.0
Some errors have detailed explanations: E0061, E0271.
For more information about an error, try `rustc --explain E0061`.
error: could not compile `iceberg` (lib test) due to 5 previous errors
warning: build failed, waiting for other jobs to finish...
make: *** [check-clippy] Error 101
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Activity
kevinjqliu commentedon Sep 3, 2026
we've seen conflicting merges several times already, I wonder if we should add merge queue. I'm giving it a try for iceberg-python (apache/iceberg-python#3832)
kevinjqliu commentedon Sep 3, 2026
github issue for enabling merge queue: #3140