You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datafusion.apache.org by gi...@apache.org on 2026/06/27 11:22:31 UTC

(datafusion) 01/01: chore(datasource): remove deprecated add_row_stats (Closes #23080 - partial) (#23134)

This is an automated email from the ASF dual-hosted git repository.

github-merge-queue[bot] pushed a commit to branch gh-readonly-queue/main/pr-23134-32d3d3a0e3ec69cdc1795240d7a0ba0f2b9c38b0
in repository https://gitbox.apache.org/repos/asf/datafusion.git

commit 66e6ea5a18edabd516c7f8b2dd82507d4e9e2b82
Author: Giorgio Maria Federico Birnthaler <12...@users.noreply.github.com>
AuthorDate: Sat Jun 27 13:22:11 2026 +0200

    chore(datasource): remove deprecated add_row_stats (Closes #23080 - partial) (#23134)
    
    Removes datafusion_datasource::add_row_stats (deprecated since 47.0.0
    with replacement Statistics::add). Zero callers — the only references
    are the deprecated function definition and a single pub use re-export
    (carrying an explicit 'Remove when add_row_stats is remove' comment,
    indicating this was already acknowledged as future work). Pure 11-line
    deletion across 2 files. Closes #23080 (partial - fourth in housekeeping
    series after #23129, #23131, #23132). AI assistance: used an AI coding
    assistant; verified via repo-wide grep that the function has no callers.
---
 datafusion/datasource/src/mod.rs        | 7 ++-----
 datafusion/datasource/src/statistics.rs | 8 --------
 2 files changed, 2 insertions(+), 13 deletions(-)

diff --git a/datafusion/datasource/src/mod.rs b/datafusion/datasource/src/mod.rs
index d4dfa1180e..7c8cae337f 100644
--- a/datafusion/datasource/src/mod.rs
+++ b/datafusion/datasource/src/mod.rs
@@ -55,6 +55,7 @@ pub mod write;
 pub use self::file::as_file_source;
 pub use self::url::ListingTableUrl;
 use crate::file_groups::FileGroup;
+use arrow::datatypes::SchemaRef;
 use chrono::TimeZone;
 use datafusion_common::stats::Precision;
 use datafusion_common::{ColumnStatistics, Result, TableReference};
@@ -62,15 +63,11 @@ use datafusion_common::{ScalarValue, Statistics};
 use datafusion_physical_expr::LexOrdering;
 use futures::Stream;
 use object_store::{ObjectMeta, path::Path};
-pub use table_schema::{TableSchema, TableSchemaBuilder};
-// Remove when add_row_stats is remove
-use arrow::datatypes::SchemaRef;
-#[expect(deprecated)]
-pub use statistics::add_row_stats;
 pub use statistics::compute_all_files_statistics;
 use std::any::Any;
 use std::pin::Pin;
 use std::sync::Arc;
+pub use table_schema::{TableSchema, TableSchemaBuilder};
 
 /// User-defined per-file extension data, keyed by concrete Rust type.
 ///
diff --git a/datafusion/datasource/src/statistics.rs b/datafusion/datasource/src/statistics.rs
index 6abfafe9d3..781cf3dbce 100644
--- a/datafusion/datasource/src/statistics.rs
+++ b/datafusion/datasource/src/statistics.rs
@@ -541,14 +541,6 @@ pub fn compute_all_files_statistics(
     Ok((file_groups_with_stats, statistics))
 }
 
-#[deprecated(since = "47.0.0", note = "Use Statistics::add")]
-pub fn add_row_stats(
-    file_num_rows: Precision<usize>,
-    num_rows: Precision<usize>,
-) -> Precision<usize> {
-    file_num_rows.add(&num_rows)
-}
-
 #[cfg(test)]
 mod tests {
     use super::*;


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org